{
 "cells": [
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "# 互评數據，不互评代码 参考代码：week03-week04\n",
    "  1.  观察三变量+一关键词的url。\n",
    "  2.  解析url参数，\n",
    "  3.  创建payload模版，\n",
    "  4.  xpath解析页面数据，\n",
    "  5.  翻页（可参考之前翻页参数模版））"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 4,
   "metadata": {},
   "outputs": [],
   "source": [
    "from requests_html import HTMLSession\n",
    "from urllib.parse import urlparse, parse_qs\n",
    "import pandas as pd\n",
    "session =HTMLSession()"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "# 猎聘抓取职位信息函数"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 90,
   "metadata": {},
   "outputs": [],
   "source": [
    "def requests_liepin( url, params):\n",
    "    r = session.get( url , params = payload)\n",
    "\n",
    "    # 先取特定元素, 精准打击其子后辈\n",
    "    主要元素 = r.html.xpath( '//ul[@class=\"sojob-list\"]/li')\n",
    "\n",
    "    # 作为xpath字典，键为我要抓的牛肉名称，值为xpath\n",
    "    dict_xpaths={ \n",
    "        'text': {\n",
    "            'edu':      '//div[contains(@class,\"job-info\")]/p/span[@class=\"edu\"]',\n",
    "            '经验':      '//div[contains(@class,\"job-info\")]/p/span[@class=\"edu\"]/following-sibling::span',\n",
    "            '薪水':    '//div[contains(@class,\"job-info\")]/p/span[@class=\"text-warning\"]', \n",
    "            '时间':    '//div[contains(@class,\"job-info\")]/p/time/@title', \n",
    "            '职称':    '//div[contains(@class,\"job-info\")]/h3/a', \n",
    "            '公司地点': '//div[contains(@class,\"job-info\")]/p/a',\n",
    "            '公司名称': '//div[contains(@class,\"sojob-item-main\")]//p[@class=\"company-name\"]/a', \n",
    "        },\n",
    "        'text_content': {\n",
    "        },\n",
    "        'href': {\n",
    "            '链结':    '//div[contains(@class,\"job-info\")]/h3/a', \n",
    "            '公司URL': '//div[contains(@class,\"sojob-item-main\")]//p[@class=\"company-name\"]/a', \n",
    "        }\n",
    "    }\n",
    "\n",
    "    def get_e_text_content(_xpath_):\n",
    "        # 高级列表推导\n",
    "        暂存结果 = [e.xpath(_xpath_)[0].lxml.text_content() for e in 主要元素]\n",
    "        return(暂存结果)\n",
    "\n",
    "    def get_e_text(_xpath_):\n",
    "        # 高级列表推导\n",
    "        暂存结果 = [\"\".join([x.strip() if type(x) is str else x.text.strip() for x in e.xpath(_xpath_)]) for e in 主要元素]\n",
    "        return(暂存结果)\n",
    "\n",
    "    def get_e_href(_xpath_):\n",
    "        # 高级列表推导\n",
    "        暂存结果 = [list(e.xpath(_xpath_, first=True).absolute_links)[0] \\\n",
    "                   if len(e.xpath(_xpath_, first=True).absolute_links) >= 1  \\\n",
    "                   else \"\" for e in 主要元素]\n",
    "        return(暂存结果)\n",
    "\n",
    "    # 只对主要元素下进行.xpath取值\n",
    "    数据字典 = dict()\n",
    "\n",
    "    数据字典 = {k:get_e_text_content(v) for k,v in dict_xpaths['text_content'].items()}\n",
    "    数据字典.update({k:get_e_text(v) for k,v in dict_xpaths['text'].items()})\n",
    "    数据字典.update({k:get_e_href(v) for k,v in dict_xpaths['href'].items()})\n",
    "\n",
    "    数据 = pd.DataFrame(数据字典)\n",
    "    #数据.to_excel(\"20春_Web数据挖掘_week03_liepin.xlsx\", sheet_name=\"搜查结果\")\n",
    "    return (数据)"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "# 翻页\n"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 166,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "{0: {'compIds': ['7983148'],\n",
       "  'key': ['数据挖掘'],\n",
       "  'init': ['-1'],\n",
       "  'searchType': ['1'],\n",
       "  'headckid': ['aa4a3ef545437f22'],\n",
       "  'fromSearchBtn': ['2'],\n",
       "  'sortFlag': ['15'],\n",
       "  'ckid': ['ddd6882081d20e94°radeFlag=0'],\n",
       "  'siTag': ['bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw'],\n",
       "  'd_sfrom': ['search_prime'],\n",
       "  'd_ckId': ['591ebc1760fee953b72353bace17e6cc'],\n",
       "  'd_curPage': ['0'],\n",
       "  'd_pageSize': ['40'],\n",
       "  'd_headId': ['591ebc1760fee953b72353bace17e6cc'],\n",
       "  'curPage': [0]},\n",
       " 1: {'compIds': ['7983148'],\n",
       "  'key': ['数据挖掘'],\n",
       "  'init': ['-1'],\n",
       "  'searchType': ['1'],\n",
       "  'headckid': ['aa4a3ef545437f22'],\n",
       "  'fromSearchBtn': ['2'],\n",
       "  'sortFlag': ['15'],\n",
       "  'ckid': ['ddd6882081d20e94°radeFlag=0'],\n",
       "  'siTag': ['bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw'],\n",
       "  'd_sfrom': ['search_prime'],\n",
       "  'd_ckId': ['591ebc1760fee953b72353bace17e6cc'],\n",
       "  'd_curPage': ['0'],\n",
       "  'd_pageSize': ['40'],\n",
       "  'd_headId': ['591ebc1760fee953b72353bace17e6cc'],\n",
       "  'curPage': [1]}}"
      ]
     },
     "execution_count": 166,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "url=\"https://www.liepin.com/zhaopin/?isAnalysis=&dqs=&pubTime=&salary=&compIds=7983148&subIndustry=&industryType=&compscale=&key=%E6%95%B0%E6%8D%AE%E5%88%86%E6%9E%90%E5%B8%88&init=-1&searchType=1&headckid=aa4a3ef545437f22&flushckid=1&compkind=&fromSearchBtn=2&sortFlag=15&ckid=aa4a3ef545437f22&jobKind=&industries=&clean_condition=&siTag=bFGQTbwE_AAQSb-u11jrBw%7EfA9rXquZc5IkJpXC-Ycixw&d_sfrom=search_prime&d_ckId=591ebc1760fee953b72353bace17e6cc&d_curPage=0&d_pageSize=40&d_headId=591ebc1760fee953b72353bace17e6cc\"\n",
    "r=session.get(url)\n",
    "xpath_翻页a = '//div[@class=\"pagerbar\"]/a[starts-with(@href,\"/zhaopin\")]'\n",
    "翻页url={x.text:x.xpath('//@href')[0] for x in r.html.xpath(xpath_翻页a)}\n",
    "翻页url\n",
    "href_翻页=[x.xpath('//@href')[0] for x in r.html.xpath(xpath_翻页a)]\n",
    "df=pd.DataFrame([urlparse(x) for x in href_翻页 ])\n",
    "df_qs=pd.DataFrame([{ k:v[0] for k,v in parse_qs(x).items()}for x in df['query']])\n",
    "df_qs = df_qs.assign (curPage_int=df_qs.curPage.astype(int)) \n",
    "df_qs\n",
    "长度=int(df_qs.curPage_int.max()+1)\n",
    "def 翻页_参数拆解(url):\n",
    "    sixpart=urlparse(url)\n",
    "    out=parse_qs(sixpart.query)\n",
    "    return out\n",
    "\n",
    "翻页_参数模板=翻页_参数拆解(href_翻页[0])\n",
    "翻页_参数模板\n",
    "def 翻页_参数调整(key,curPage,compIds):\n",
    "    参数=翻页_参数模板.copy()\n",
    "    参数['key']=key\n",
    "    参数['curPage']=curPage\n",
    "    参数['compIds']=compIds\n",
    "    return 参数\n",
    "指定公司_关键词_翻页参数={i:翻页_参数调整(key=['数据挖掘'],compIds=['7983148'],curPage = [i])\n",
    "                                   for i in  range(0,长度)\n",
    "                                  }\n",
    "\n",
    "指定公司_关键词_翻页参数"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "# 指定公司"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 161,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>compIds</th>\n",
       "      <th>key</th>\n",
       "      <th>init</th>\n",
       "      <th>searchType</th>\n",
       "      <th>headckid</th>\n",
       "      <th>flushckid</th>\n",
       "      <th>fromSearchBtn</th>\n",
       "      <th>sortFlag</th>\n",
       "      <th>ckid</th>\n",
       "      <th>siTag</th>\n",
       "      <th>d_sfrom</th>\n",
       "      <th>d_ckId</th>\n",
       "      <th>d_curPage</th>\n",
       "      <th>d_pageSize</th>\n",
       "      <th>d_headId</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>7863078</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>7a115a2bab7b46bd</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>7a115a2bab7b46bd</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>2034a31bfcfa807d59b3bca7745ed138</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>2034a31bfcfa807d59b3bca7745ed138</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td>7983148</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>7a115a2bab7b46bd</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>7a115a2bab7b46bd</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>2034a31bfcfa807d59b3bca7745ed138</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>2034a31bfcfa807d59b3bca7745ed138</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>8983822</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>7a115a2bab7b46bd</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>7a115a2bab7b46bd</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>2034a31bfcfa807d59b3bca7745ed138</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>2034a31bfcfa807d59b3bca7745ed138</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>3</th>\n",
       "      <td>8076624</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>7a115a2bab7b46bd</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>7a115a2bab7b46bd</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>2034a31bfcfa807d59b3bca7745ed138</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>2034a31bfcfa807d59b3bca7745ed138</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>4</th>\n",
       "      <td>2778803</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>7a115a2bab7b46bd</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>7a115a2bab7b46bd</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>2034a31bfcfa807d59b3bca7745ed138</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>2034a31bfcfa807d59b3bca7745ed138</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>5</th>\n",
       "      <td>9747025</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>7a115a2bab7b46bd</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>7a115a2bab7b46bd</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>2034a31bfcfa807d59b3bca7745ed138</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>2034a31bfcfa807d59b3bca7745ed138</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>6</th>\n",
       "      <td>591850</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>7a115a2bab7b46bd</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>7a115a2bab7b46bd</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>2034a31bfcfa807d59b3bca7745ed138</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>2034a31bfcfa807d59b3bca7745ed138</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>7</th>\n",
       "      <td>8089425</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>7a115a2bab7b46bd</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>7a115a2bab7b46bd</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>2034a31bfcfa807d59b3bca7745ed138</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>2034a31bfcfa807d59b3bca7745ed138</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>8</th>\n",
       "      <td>2036768</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>7a115a2bab7b46bd</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>7a115a2bab7b46bd</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>2034a31bfcfa807d59b3bca7745ed138</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>2034a31bfcfa807d59b3bca7745ed138</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>9</th>\n",
       "      <td>4787049</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>7a115a2bab7b46bd</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>7a115a2bab7b46bd</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>2034a31bfcfa807d59b3bca7745ed138</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>2034a31bfcfa807d59b3bca7745ed138</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>10</th>\n",
       "      <td>8640905</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>7a115a2bab7b46bd</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>7a115a2bab7b46bd</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>2034a31bfcfa807d59b3bca7745ed138</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>2034a31bfcfa807d59b3bca7745ed138</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>11</th>\n",
       "      <td>1072424</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>7a115a2bab7b46bd</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>7a115a2bab7b46bd</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>2034a31bfcfa807d59b3bca7745ed138</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>2034a31bfcfa807d59b3bca7745ed138</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>12</th>\n",
       "      <td>2174886</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>7a115a2bab7b46bd</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>7a115a2bab7b46bd</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>2034a31bfcfa807d59b3bca7745ed138</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>2034a31bfcfa807d59b3bca7745ed138</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>13</th>\n",
       "      <td>8537928</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>7a115a2bab7b46bd</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>7a115a2bab7b46bd</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>2034a31bfcfa807d59b3bca7745ed138</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>2034a31bfcfa807d59b3bca7745ed138</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>14</th>\n",
       "      <td>182339</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>7a115a2bab7b46bd</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>7a115a2bab7b46bd</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>2034a31bfcfa807d59b3bca7745ed138</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>2034a31bfcfa807d59b3bca7745ed138</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>15</th>\n",
       "      <td>8830801</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>7a115a2bab7b46bd</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>7a115a2bab7b46bd</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>2034a31bfcfa807d59b3bca7745ed138</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>2034a31bfcfa807d59b3bca7745ed138</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>16</th>\n",
       "      <td>8660469</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>7a115a2bab7b46bd</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>7a115a2bab7b46bd</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>2034a31bfcfa807d59b3bca7745ed138</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>2034a31bfcfa807d59b3bca7745ed138</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>17</th>\n",
       "      <td>2399664</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>7a115a2bab7b46bd</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>7a115a2bab7b46bd</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>2034a31bfcfa807d59b3bca7745ed138</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>2034a31bfcfa807d59b3bca7745ed138</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>18</th>\n",
       "      <td>8899712</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>7a115a2bab7b46bd</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>7a115a2bab7b46bd</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>2034a31bfcfa807d59b3bca7745ed138</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>2034a31bfcfa807d59b3bca7745ed138</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>19</th>\n",
       "      <td>884492</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>7a115a2bab7b46bd</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>7a115a2bab7b46bd</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>2034a31bfcfa807d59b3bca7745ed138</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>2034a31bfcfa807d59b3bca7745ed138</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>20</th>\n",
       "      <td>9469266</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>7a115a2bab7b46bd</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>7a115a2bab7b46bd</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>2034a31bfcfa807d59b3bca7745ed138</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>2034a31bfcfa807d59b3bca7745ed138</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>21</th>\n",
       "      <td>2638985</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>7a115a2bab7b46bd</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>7a115a2bab7b46bd</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>2034a31bfcfa807d59b3bca7745ed138</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>2034a31bfcfa807d59b3bca7745ed138</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>22</th>\n",
       "      <td>8605497</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>7a115a2bab7b46bd</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>7a115a2bab7b46bd</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>2034a31bfcfa807d59b3bca7745ed138</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>2034a31bfcfa807d59b3bca7745ed138</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>23</th>\n",
       "      <td>8621471</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>7a115a2bab7b46bd</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>7a115a2bab7b46bd</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>2034a31bfcfa807d59b3bca7745ed138</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>2034a31bfcfa807d59b3bca7745ed138</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>24</th>\n",
       "      <td>8084886</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>7a115a2bab7b46bd</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>7a115a2bab7b46bd</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>2034a31bfcfa807d59b3bca7745ed138</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>2034a31bfcfa807d59b3bca7745ed138</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>25</th>\n",
       "      <td>5964833</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>7a115a2bab7b46bd</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>7a115a2bab7b46bd</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>2034a31bfcfa807d59b3bca7745ed138</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>2034a31bfcfa807d59b3bca7745ed138</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>26</th>\n",
       "      <td>8461883</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>7a115a2bab7b46bd</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>7a115a2bab7b46bd</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>2034a31bfcfa807d59b3bca7745ed138</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>2034a31bfcfa807d59b3bca7745ed138</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>27</th>\n",
       "      <td>9630160</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>7a115a2bab7b46bd</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>7a115a2bab7b46bd</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>2034a31bfcfa807d59b3bca7745ed138</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>2034a31bfcfa807d59b3bca7745ed138</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>28</th>\n",
       "      <td>10023177</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>7a115a2bab7b46bd</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>7a115a2bab7b46bd</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>2034a31bfcfa807d59b3bca7745ed138</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>2034a31bfcfa807d59b3bca7745ed138</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>29</th>\n",
       "      <td>12176713</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>7a115a2bab7b46bd</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>7a115a2bab7b46bd</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>2034a31bfcfa807d59b3bca7745ed138</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>2034a31bfcfa807d59b3bca7745ed138</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>30</th>\n",
       "      <td>7865459</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>7a115a2bab7b46bd</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>7a115a2bab7b46bd</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>2034a31bfcfa807d59b3bca7745ed138</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>2034a31bfcfa807d59b3bca7745ed138</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>31</th>\n",
       "      <td>9142549</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>7a115a2bab7b46bd</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>7a115a2bab7b46bd</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>2034a31bfcfa807d59b3bca7745ed138</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>2034a31bfcfa807d59b3bca7745ed138</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>32</th>\n",
       "      <td>2020322</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>7a115a2bab7b46bd</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>7a115a2bab7b46bd</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>2034a31bfcfa807d59b3bca7745ed138</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>2034a31bfcfa807d59b3bca7745ed138</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>33</th>\n",
       "      <td>3922321</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>7a115a2bab7b46bd</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>7a115a2bab7b46bd</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>2034a31bfcfa807d59b3bca7745ed138</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>2034a31bfcfa807d59b3bca7745ed138</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>34</th>\n",
       "      <td>7956861</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>7a115a2bab7b46bd</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>7a115a2bab7b46bd</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>2034a31bfcfa807d59b3bca7745ed138</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>2034a31bfcfa807d59b3bca7745ed138</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "     compIds    key init searchType          headckid flushckid fromSearchBtn  \\\n",
       "0    7863078  数据分析师   -1          1  7a115a2bab7b46bd         1             2   \n",
       "1    7983148  数据分析师   -1          1  7a115a2bab7b46bd         1             2   \n",
       "2    8983822  数据分析师   -1          1  7a115a2bab7b46bd         1             2   \n",
       "3    8076624  数据分析师   -1          1  7a115a2bab7b46bd         1             2   \n",
       "4    2778803  数据分析师   -1          1  7a115a2bab7b46bd         1             2   \n",
       "5    9747025  数据分析师   -1          1  7a115a2bab7b46bd         1             2   \n",
       "6     591850  数据分析师   -1          1  7a115a2bab7b46bd         1             2   \n",
       "7    8089425  数据分析师   -1          1  7a115a2bab7b46bd         1             2   \n",
       "8    2036768  数据分析师   -1          1  7a115a2bab7b46bd         1             2   \n",
       "9    4787049  数据分析师   -1          1  7a115a2bab7b46bd         1             2   \n",
       "10   8640905  数据分析师   -1          1  7a115a2bab7b46bd         1             2   \n",
       "11   1072424  数据分析师   -1          1  7a115a2bab7b46bd         1             2   \n",
       "12   2174886  数据分析师   -1          1  7a115a2bab7b46bd         1             2   \n",
       "13   8537928  数据分析师   -1          1  7a115a2bab7b46bd         1             2   \n",
       "14    182339  数据分析师   -1          1  7a115a2bab7b46bd         1             2   \n",
       "15   8830801  数据分析师   -1          1  7a115a2bab7b46bd         1             2   \n",
       "16   8660469  数据分析师   -1          1  7a115a2bab7b46bd         1             2   \n",
       "17   2399664  数据分析师   -1          1  7a115a2bab7b46bd         1             2   \n",
       "18   8899712  数据分析师   -1          1  7a115a2bab7b46bd         1             2   \n",
       "19    884492  数据分析师   -1          1  7a115a2bab7b46bd         1             2   \n",
       "20   9469266  数据分析师   -1          1  7a115a2bab7b46bd         1             2   \n",
       "21   2638985  数据分析师   -1          1  7a115a2bab7b46bd         1             2   \n",
       "22   8605497  数据分析师   -1          1  7a115a2bab7b46bd         1             2   \n",
       "23   8621471  数据分析师   -1          1  7a115a2bab7b46bd         1             2   \n",
       "24   8084886  数据分析师   -1          1  7a115a2bab7b46bd         1             2   \n",
       "25   5964833  数据分析师   -1          1  7a115a2bab7b46bd         1             2   \n",
       "26   8461883  数据分析师   -1          1  7a115a2bab7b46bd         1             2   \n",
       "27   9630160  数据分析师   -1          1  7a115a2bab7b46bd         1             2   \n",
       "28  10023177  数据分析师   -1          1  7a115a2bab7b46bd         1             2   \n",
       "29  12176713  数据分析师   -1          1  7a115a2bab7b46bd         1             2   \n",
       "30   7865459  数据分析师   -1          1  7a115a2bab7b46bd         1             2   \n",
       "31   9142549  数据分析师   -1          1  7a115a2bab7b46bd         1             2   \n",
       "32   2020322  数据分析师   -1          1  7a115a2bab7b46bd         1             2   \n",
       "33   3922321  数据分析师   -1          1  7a115a2bab7b46bd         1             2   \n",
       "34   7956861  数据分析师   -1          1  7a115a2bab7b46bd         1             2   \n",
       "\n",
       "   sortFlag              ckid                                          siTag  \\\n",
       "0        15  7a115a2bab7b46bd  bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw   \n",
       "1        15  7a115a2bab7b46bd  bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw   \n",
       "2        15  7a115a2bab7b46bd  bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw   \n",
       "3        15  7a115a2bab7b46bd  bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw   \n",
       "4        15  7a115a2bab7b46bd  bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw   \n",
       "5        15  7a115a2bab7b46bd  bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw   \n",
       "6        15  7a115a2bab7b46bd  bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw   \n",
       "7        15  7a115a2bab7b46bd  bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw   \n",
       "8        15  7a115a2bab7b46bd  bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw   \n",
       "9        15  7a115a2bab7b46bd  bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw   \n",
       "10       15  7a115a2bab7b46bd  bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw   \n",
       "11       15  7a115a2bab7b46bd  bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw   \n",
       "12       15  7a115a2bab7b46bd  bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw   \n",
       "13       15  7a115a2bab7b46bd  bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw   \n",
       "14       15  7a115a2bab7b46bd  bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw   \n",
       "15       15  7a115a2bab7b46bd  bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw   \n",
       "16       15  7a115a2bab7b46bd  bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw   \n",
       "17       15  7a115a2bab7b46bd  bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw   \n",
       "18       15  7a115a2bab7b46bd  bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw   \n",
       "19       15  7a115a2bab7b46bd  bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw   \n",
       "20       15  7a115a2bab7b46bd  bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw   \n",
       "21       15  7a115a2bab7b46bd  bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw   \n",
       "22       15  7a115a2bab7b46bd  bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw   \n",
       "23       15  7a115a2bab7b46bd  bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw   \n",
       "24       15  7a115a2bab7b46bd  bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw   \n",
       "25       15  7a115a2bab7b46bd  bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw   \n",
       "26       15  7a115a2bab7b46bd  bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw   \n",
       "27       15  7a115a2bab7b46bd  bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw   \n",
       "28       15  7a115a2bab7b46bd  bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw   \n",
       "29       15  7a115a2bab7b46bd  bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw   \n",
       "30       15  7a115a2bab7b46bd  bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw   \n",
       "31       15  7a115a2bab7b46bd  bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw   \n",
       "32       15  7a115a2bab7b46bd  bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw   \n",
       "33       15  7a115a2bab7b46bd  bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw   \n",
       "34       15  7a115a2bab7b46bd  bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw   \n",
       "\n",
       "         d_sfrom                            d_ckId d_curPage d_pageSize  \\\n",
       "0   search_prime  2034a31bfcfa807d59b3bca7745ed138         0         40   \n",
       "1   search_prime  2034a31bfcfa807d59b3bca7745ed138         0         40   \n",
       "2   search_prime  2034a31bfcfa807d59b3bca7745ed138         0         40   \n",
       "3   search_prime  2034a31bfcfa807d59b3bca7745ed138         0         40   \n",
       "4   search_prime  2034a31bfcfa807d59b3bca7745ed138         0         40   \n",
       "5   search_prime  2034a31bfcfa807d59b3bca7745ed138         0         40   \n",
       "6   search_prime  2034a31bfcfa807d59b3bca7745ed138         0         40   \n",
       "7   search_prime  2034a31bfcfa807d59b3bca7745ed138         0         40   \n",
       "8   search_prime  2034a31bfcfa807d59b3bca7745ed138         0         40   \n",
       "9   search_prime  2034a31bfcfa807d59b3bca7745ed138         0         40   \n",
       "10  search_prime  2034a31bfcfa807d59b3bca7745ed138         0         40   \n",
       "11  search_prime  2034a31bfcfa807d59b3bca7745ed138         0         40   \n",
       "12  search_prime  2034a31bfcfa807d59b3bca7745ed138         0         40   \n",
       "13  search_prime  2034a31bfcfa807d59b3bca7745ed138         0         40   \n",
       "14  search_prime  2034a31bfcfa807d59b3bca7745ed138         0         40   \n",
       "15  search_prime  2034a31bfcfa807d59b3bca7745ed138         0         40   \n",
       "16  search_prime  2034a31bfcfa807d59b3bca7745ed138         0         40   \n",
       "17  search_prime  2034a31bfcfa807d59b3bca7745ed138         0         40   \n",
       "18  search_prime  2034a31bfcfa807d59b3bca7745ed138         0         40   \n",
       "19  search_prime  2034a31bfcfa807d59b3bca7745ed138         0         40   \n",
       "20  search_prime  2034a31bfcfa807d59b3bca7745ed138         0         40   \n",
       "21  search_prime  2034a31bfcfa807d59b3bca7745ed138         0         40   \n",
       "22  search_prime  2034a31bfcfa807d59b3bca7745ed138         0         40   \n",
       "23  search_prime  2034a31bfcfa807d59b3bca7745ed138         0         40   \n",
       "24  search_prime  2034a31bfcfa807d59b3bca7745ed138         0         40   \n",
       "25  search_prime  2034a31bfcfa807d59b3bca7745ed138         0         40   \n",
       "26  search_prime  2034a31bfcfa807d59b3bca7745ed138         0         40   \n",
       "27  search_prime  2034a31bfcfa807d59b3bca7745ed138         0         40   \n",
       "28  search_prime  2034a31bfcfa807d59b3bca7745ed138         0         40   \n",
       "29  search_prime  2034a31bfcfa807d59b3bca7745ed138         0         40   \n",
       "30  search_prime  2034a31bfcfa807d59b3bca7745ed138         0         40   \n",
       "31  search_prime  2034a31bfcfa807d59b3bca7745ed138         0         40   \n",
       "32  search_prime  2034a31bfcfa807d59b3bca7745ed138         0         40   \n",
       "33  search_prime  2034a31bfcfa807d59b3bca7745ed138         0         40   \n",
       "34  search_prime  2034a31bfcfa807d59b3bca7745ed138         0         40   \n",
       "\n",
       "                            d_headId  \n",
       "0   2034a31bfcfa807d59b3bca7745ed138  \n",
       "1   2034a31bfcfa807d59b3bca7745ed138  \n",
       "2   2034a31bfcfa807d59b3bca7745ed138  \n",
       "3   2034a31bfcfa807d59b3bca7745ed138  \n",
       "4   2034a31bfcfa807d59b3bca7745ed138  \n",
       "5   2034a31bfcfa807d59b3bca7745ed138  \n",
       "6   2034a31bfcfa807d59b3bca7745ed138  \n",
       "7   2034a31bfcfa807d59b3bca7745ed138  \n",
       "8   2034a31bfcfa807d59b3bca7745ed138  \n",
       "9   2034a31bfcfa807d59b3bca7745ed138  \n",
       "10  2034a31bfcfa807d59b3bca7745ed138  \n",
       "11  2034a31bfcfa807d59b3bca7745ed138  \n",
       "12  2034a31bfcfa807d59b3bca7745ed138  \n",
       "13  2034a31bfcfa807d59b3bca7745ed138  \n",
       "14  2034a31bfcfa807d59b3bca7745ed138  \n",
       "15  2034a31bfcfa807d59b3bca7745ed138  \n",
       "16  2034a31bfcfa807d59b3bca7745ed138  \n",
       "17  2034a31bfcfa807d59b3bca7745ed138  \n",
       "18  2034a31bfcfa807d59b3bca7745ed138  \n",
       "19  2034a31bfcfa807d59b3bca7745ed138  \n",
       "20  2034a31bfcfa807d59b3bca7745ed138  \n",
       "21  2034a31bfcfa807d59b3bca7745ed138  \n",
       "22  2034a31bfcfa807d59b3bca7745ed138  \n",
       "23  2034a31bfcfa807d59b3bca7745ed138  \n",
       "24  2034a31bfcfa807d59b3bca7745ed138  \n",
       "25  2034a31bfcfa807d59b3bca7745ed138  \n",
       "26  2034a31bfcfa807d59b3bca7745ed138  \n",
       "27  2034a31bfcfa807d59b3bca7745ed138  \n",
       "28  2034a31bfcfa807d59b3bca7745ed138  \n",
       "29  2034a31bfcfa807d59b3bca7745ed138  \n",
       "30  2034a31bfcfa807d59b3bca7745ed138  \n",
       "31  2034a31bfcfa807d59b3bca7745ed138  \n",
       "32  2034a31bfcfa807d59b3bca7745ed138  \n",
       "33  2034a31bfcfa807d59b3bca7745ed138  \n",
       "34  2034a31bfcfa807d59b3bca7745ed138  "
      ]
     },
     "metadata": {},
     "output_type": "display_data"
    },
    {
     "data": {
      "text/plain": [
       "{'字节跳动': {'compIds': ['7863078'],\n",
       "  'key': ['产品经理'],\n",
       "  'init': ['-1'],\n",
       "  'searchType': ['1'],\n",
       "  'headckid': ['7a115a2bab7b46bd'],\n",
       "  'flushckid': ['1'],\n",
       "  'fromSearchBtn': ['2'],\n",
       "  'sortFlag': ['15'],\n",
       "  'ckid': ['7a115a2bab7b46bd'],\n",
       "  'siTag': ['bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw'],\n",
       "  'd_sfrom': ['search_prime'],\n",
       "  'd_ckId': ['2034a31bfcfa807d59b3bca7745ed138'],\n",
       "  'd_curPage': ['0'],\n",
       "  'd_pageSize': ['40'],\n",
       "  'd_headId': ['2034a31bfcfa807d59b3bca7745ed138']},\n",
       " '腾讯': {'compIds': ['7983148'],\n",
       "  'key': ['产品经理'],\n",
       "  'init': ['-1'],\n",
       "  'searchType': ['1'],\n",
       "  'headckid': ['7a115a2bab7b46bd'],\n",
       "  'flushckid': ['1'],\n",
       "  'fromSearchBtn': ['2'],\n",
       "  'sortFlag': ['15'],\n",
       "  'ckid': ['7a115a2bab7b46bd'],\n",
       "  'siTag': ['bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw'],\n",
       "  'd_sfrom': ['search_prime'],\n",
       "  'd_ckId': ['2034a31bfcfa807d59b3bca7745ed138'],\n",
       "  'd_curPage': ['0'],\n",
       "  'd_pageSize': ['40'],\n",
       "  'd_headId': ['2034a31bfcfa807d59b3bca7745ed138']},\n",
       " '便利蜂': {'compIds': ['8983822'],\n",
       "  'key': ['产品经理'],\n",
       "  'init': ['-1'],\n",
       "  'searchType': ['1'],\n",
       "  'headckid': ['7a115a2bab7b46bd'],\n",
       "  'flushckid': ['1'],\n",
       "  'fromSearchBtn': ['2'],\n",
       "  'sortFlag': ['15'],\n",
       "  'ckid': ['7a115a2bab7b46bd'],\n",
       "  'siTag': ['bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw'],\n",
       "  'd_sfrom': ['search_prime'],\n",
       "  'd_ckId': ['2034a31bfcfa807d59b3bca7745ed138'],\n",
       "  'd_curPage': ['0'],\n",
       "  'd_pageSize': ['40'],\n",
       "  'd_headId': ['2034a31bfcfa807d59b3bca7745ed138']},\n",
       " '滴滴': {'compIds': ['8076624'],\n",
       "  'key': ['产品经理'],\n",
       "  'init': ['-1'],\n",
       "  'searchType': ['1'],\n",
       "  'headckid': ['7a115a2bab7b46bd'],\n",
       "  'flushckid': ['1'],\n",
       "  'fromSearchBtn': ['2'],\n",
       "  'sortFlag': ['15'],\n",
       "  'ckid': ['7a115a2bab7b46bd'],\n",
       "  'siTag': ['bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw'],\n",
       "  'd_sfrom': ['search_prime'],\n",
       "  'd_ckId': ['2034a31bfcfa807d59b3bca7745ed138'],\n",
       "  'd_curPage': ['0'],\n",
       "  'd_pageSize': ['40'],\n",
       "  'd_headId': ['2034a31bfcfa807d59b3bca7745ed138']},\n",
       " '饿了么': {'compIds': ['2778803'],\n",
       "  'key': ['产品经理'],\n",
       "  'init': ['-1'],\n",
       "  'searchType': ['1'],\n",
       "  'headckid': ['7a115a2bab7b46bd'],\n",
       "  'flushckid': ['1'],\n",
       "  'fromSearchBtn': ['2'],\n",
       "  'sortFlag': ['15'],\n",
       "  'ckid': ['7a115a2bab7b46bd'],\n",
       "  'siTag': ['bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw'],\n",
       "  'd_sfrom': ['search_prime'],\n",
       "  'd_ckId': ['2034a31bfcfa807d59b3bca7745ed138'],\n",
       "  'd_curPage': ['0'],\n",
       "  'd_pageSize': ['40'],\n",
       "  'd_headId': ['2034a31bfcfa807d59b3bca7745ed138']},\n",
       " '京东商城': {'compIds': ['9747025'],\n",
       "  'key': ['产品经理'],\n",
       "  'init': ['-1'],\n",
       "  'searchType': ['1'],\n",
       "  'headckid': ['7a115a2bab7b46bd'],\n",
       "  'flushckid': ['1'],\n",
       "  'fromSearchBtn': ['2'],\n",
       "  'sortFlag': ['15'],\n",
       "  'ckid': ['7a115a2bab7b46bd'],\n",
       "  'siTag': ['bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw'],\n",
       "  'd_sfrom': ['search_prime'],\n",
       "  'd_ckId': ['2034a31bfcfa807d59b3bca7745ed138'],\n",
       "  'd_curPage': ['0'],\n",
       "  'd_pageSize': ['40'],\n",
       "  'd_headId': ['2034a31bfcfa807d59b3bca7745ed138']},\n",
       " '58同城': {'compIds': ['591850'],\n",
       "  'key': ['产品经理'],\n",
       "  'init': ['-1'],\n",
       "  'searchType': ['1'],\n",
       "  'headckid': ['7a115a2bab7b46bd'],\n",
       "  'flushckid': ['1'],\n",
       "  'fromSearchBtn': ['2'],\n",
       "  'sortFlag': ['15'],\n",
       "  'ckid': ['7a115a2bab7b46bd'],\n",
       "  'siTag': ['bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw'],\n",
       "  'd_sfrom': ['search_prime'],\n",
       "  'd_ckId': ['2034a31bfcfa807d59b3bca7745ed138'],\n",
       "  'd_curPage': ['0'],\n",
       "  'd_pageSize': ['40'],\n",
       "  'd_headId': ['2034a31bfcfa807d59b3bca7745ed138']},\n",
       " '北京国富如荷网络科技有限公司': {'compIds': ['8089425'],\n",
       "  'key': ['产品经理'],\n",
       "  'init': ['-1'],\n",
       "  'searchType': ['1'],\n",
       "  'headckid': ['7a115a2bab7b46bd'],\n",
       "  'flushckid': ['1'],\n",
       "  'fromSearchBtn': ['2'],\n",
       "  'sortFlag': ['15'],\n",
       "  'ckid': ['7a115a2bab7b46bd'],\n",
       "  'siTag': ['bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw'],\n",
       "  'd_sfrom': ['search_prime'],\n",
       "  'd_ckId': ['2034a31bfcfa807d59b3bca7745ed138'],\n",
       "  'd_curPage': ['0'],\n",
       "  'd_pageSize': ['40'],\n",
       "  'd_headId': ['2034a31bfcfa807d59b3bca7745ed138']},\n",
       " '美团点评': {'compIds': ['2036768'],\n",
       "  'key': ['产品经理'],\n",
       "  'init': ['-1'],\n",
       "  'searchType': ['1'],\n",
       "  'headckid': ['7a115a2bab7b46bd'],\n",
       "  'flushckid': ['1'],\n",
       "  'fromSearchBtn': ['2'],\n",
       "  'sortFlag': ['15'],\n",
       "  'ckid': ['7a115a2bab7b46bd'],\n",
       "  'siTag': ['bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw'],\n",
       "  'd_sfrom': ['search_prime'],\n",
       "  'd_ckId': ['2034a31bfcfa807d59b3bca7745ed138'],\n",
       "  'd_curPage': ['0'],\n",
       "  'd_pageSize': ['40'],\n",
       "  'd_headId': ['2034a31bfcfa807d59b3bca7745ed138']},\n",
       " 'vivo': {'compIds': ['4787049'],\n",
       "  'key': ['产品经理'],\n",
       "  'init': ['-1'],\n",
       "  'searchType': ['1'],\n",
       "  'headckid': ['7a115a2bab7b46bd'],\n",
       "  'flushckid': ['1'],\n",
       "  'fromSearchBtn': ['2'],\n",
       "  'sortFlag': ['15'],\n",
       "  'ckid': ['7a115a2bab7b46bd'],\n",
       "  'siTag': ['bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw'],\n",
       "  'd_sfrom': ['search_prime'],\n",
       "  'd_ckId': ['2034a31bfcfa807d59b3bca7745ed138'],\n",
       "  'd_curPage': ['0'],\n",
       "  'd_pageSize': ['40'],\n",
       "  'd_headId': ['2034a31bfcfa807d59b3bca7745ed138']},\n",
       " '岩心科技': {'compIds': ['8640905'],\n",
       "  'key': ['产品经理'],\n",
       "  'init': ['-1'],\n",
       "  'searchType': ['1'],\n",
       "  'headckid': ['7a115a2bab7b46bd'],\n",
       "  'flushckid': ['1'],\n",
       "  'fromSearchBtn': ['2'],\n",
       "  'sortFlag': ['15'],\n",
       "  'ckid': ['7a115a2bab7b46bd'],\n",
       "  'siTag': ['bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw'],\n",
       "  'd_sfrom': ['search_prime'],\n",
       "  'd_ckId': ['2034a31bfcfa807d59b3bca7745ed138'],\n",
       "  'd_curPage': ['0'],\n",
       "  'd_pageSize': ['40'],\n",
       "  'd_headId': ['2034a31bfcfa807d59b3bca7745ed138']},\n",
       " '阿里巴巴': {'compIds': ['1072424'],\n",
       "  'key': ['产品经理'],\n",
       "  'init': ['-1'],\n",
       "  'searchType': ['1'],\n",
       "  'headckid': ['7a115a2bab7b46bd'],\n",
       "  'flushckid': ['1'],\n",
       "  'fromSearchBtn': ['2'],\n",
       "  'sortFlag': ['15'],\n",
       "  'ckid': ['7a115a2bab7b46bd'],\n",
       "  'siTag': ['bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw'],\n",
       "  'd_sfrom': ['search_prime'],\n",
       "  'd_ckId': ['2034a31bfcfa807d59b3bca7745ed138'],\n",
       "  'd_curPage': ['0'],\n",
       "  'd_pageSize': ['40'],\n",
       "  'd_headId': ['2034a31bfcfa807d59b3bca7745ed138']},\n",
       " '小米': {'compIds': ['2174886'],\n",
       "  'key': ['产品经理'],\n",
       "  'init': ['-1'],\n",
       "  'searchType': ['1'],\n",
       "  'headckid': ['7a115a2bab7b46bd'],\n",
       "  'flushckid': ['1'],\n",
       "  'fromSearchBtn': ['2'],\n",
       "  'sortFlag': ['15'],\n",
       "  'ckid': ['7a115a2bab7b46bd'],\n",
       "  'siTag': ['bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw'],\n",
       "  'd_sfrom': ['search_prime'],\n",
       "  'd_ckId': ['2034a31bfcfa807d59b3bca7745ed138'],\n",
       "  'd_curPage': ['0'],\n",
       "  'd_pageSize': ['40'],\n",
       "  'd_headId': ['2034a31bfcfa807d59b3bca7745ed138']},\n",
       " '上海寻梦信息技术有限公司': {'compIds': ['8537928'],\n",
       "  'key': ['产品经理'],\n",
       "  'init': ['-1'],\n",
       "  'searchType': ['1'],\n",
       "  'headckid': ['7a115a2bab7b46bd'],\n",
       "  'flushckid': ['1'],\n",
       "  'fromSearchBtn': ['2'],\n",
       "  'sortFlag': ['15'],\n",
       "  'ckid': ['7a115a2bab7b46bd'],\n",
       "  'siTag': ['bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw'],\n",
       "  'd_sfrom': ['search_prime'],\n",
       "  'd_ckId': ['2034a31bfcfa807d59b3bca7745ed138'],\n",
       "  'd_curPage': ['0'],\n",
       "  'd_pageSize': ['40'],\n",
       "  'd_headId': ['2034a31bfcfa807d59b3bca7745ed138']},\n",
       " '携程': {'compIds': ['182339'],\n",
       "  'key': ['产品经理'],\n",
       "  'init': ['-1'],\n",
       "  'searchType': ['1'],\n",
       "  'headckid': ['7a115a2bab7b46bd'],\n",
       "  'flushckid': ['1'],\n",
       "  'fromSearchBtn': ['2'],\n",
       "  'sortFlag': ['15'],\n",
       "  'ckid': ['7a115a2bab7b46bd'],\n",
       "  'siTag': ['bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw'],\n",
       "  'd_sfrom': ['search_prime'],\n",
       "  'd_ckId': ['2034a31bfcfa807d59b3bca7745ed138'],\n",
       "  'd_curPage': ['0'],\n",
       "  'd_pageSize': ['40'],\n",
       "  'd_headId': ['2034a31bfcfa807d59b3bca7745ed138']},\n",
       " '资采信息': {'compIds': ['8830801'],\n",
       "  'key': ['产品经理'],\n",
       "  'init': ['-1'],\n",
       "  'searchType': ['1'],\n",
       "  'headckid': ['7a115a2bab7b46bd'],\n",
       "  'flushckid': ['1'],\n",
       "  'fromSearchBtn': ['2'],\n",
       "  'sortFlag': ['15'],\n",
       "  'ckid': ['7a115a2bab7b46bd'],\n",
       "  'siTag': ['bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw'],\n",
       "  'd_sfrom': ['search_prime'],\n",
       "  'd_ckId': ['2034a31bfcfa807d59b3bca7745ed138'],\n",
       "  'd_curPage': ['0'],\n",
       "  'd_pageSize': ['40'],\n",
       "  'd_headId': ['2034a31bfcfa807d59b3bca7745ed138']},\n",
       " '捷信消费金融有限公司': {'compIds': ['8660469'],\n",
       "  'key': ['产品经理'],\n",
       "  'init': ['-1'],\n",
       "  'searchType': ['1'],\n",
       "  'headckid': ['7a115a2bab7b46bd'],\n",
       "  'flushckid': ['1'],\n",
       "  'fromSearchBtn': ['2'],\n",
       "  'sortFlag': ['15'],\n",
       "  'ckid': ['7a115a2bab7b46bd'],\n",
       "  'siTag': ['bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw'],\n",
       "  'd_sfrom': ['search_prime'],\n",
       "  'd_ckId': ['2034a31bfcfa807d59b3bca7745ed138'],\n",
       "  'd_curPage': ['0'],\n",
       "  'd_pageSize': ['40'],\n",
       "  'd_headId': ['2034a31bfcfa807d59b3bca7745ed138']},\n",
       " '亚信科技': {'compIds': ['2399664'],\n",
       "  'key': ['产品经理'],\n",
       "  'init': ['-1'],\n",
       "  'searchType': ['1'],\n",
       "  'headckid': ['7a115a2bab7b46bd'],\n",
       "  'flushckid': ['1'],\n",
       "  'fromSearchBtn': ['2'],\n",
       "  'sortFlag': ['15'],\n",
       "  'ckid': ['7a115a2bab7b46bd'],\n",
       "  'siTag': ['bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw'],\n",
       "  'd_sfrom': ['search_prime'],\n",
       "  'd_ckId': ['2034a31bfcfa807d59b3bca7745ed138'],\n",
       "  'd_curPage': ['0'],\n",
       "  'd_pageSize': ['40'],\n",
       "  'd_headId': ['2034a31bfcfa807d59b3bca7745ed138']},\n",
       " '思爱普': {'compIds': ['8899712'],\n",
       "  'key': ['产品经理'],\n",
       "  'init': ['-1'],\n",
       "  'searchType': ['1'],\n",
       "  'headckid': ['7a115a2bab7b46bd'],\n",
       "  'flushckid': ['1'],\n",
       "  'fromSearchBtn': ['2'],\n",
       "  'sortFlag': ['15'],\n",
       "  'ckid': ['7a115a2bab7b46bd'],\n",
       "  'siTag': ['bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw'],\n",
       "  'd_sfrom': ['search_prime'],\n",
       "  'd_ckId': ['2034a31bfcfa807d59b3bca7745ed138'],\n",
       "  'd_curPage': ['0'],\n",
       "  'd_pageSize': ['40'],\n",
       "  'd_headId': ['2034a31bfcfa807d59b3bca7745ed138']},\n",
       " 'Baidu': {'compIds': ['884492'],\n",
       "  'key': ['产品经理'],\n",
       "  'init': ['-1'],\n",
       "  'searchType': ['1'],\n",
       "  'headckid': ['7a115a2bab7b46bd'],\n",
       "  'flushckid': ['1'],\n",
       "  'fromSearchBtn': ['2'],\n",
       "  'sortFlag': ['15'],\n",
       "  'ckid': ['7a115a2bab7b46bd'],\n",
       "  'siTag': ['bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw'],\n",
       "  'd_sfrom': ['search_prime'],\n",
       "  'd_ckId': ['2034a31bfcfa807d59b3bca7745ed138'],\n",
       "  'd_curPage': ['0'],\n",
       "  'd_pageSize': ['40'],\n",
       "  'd_headId': ['2034a31bfcfa807d59b3bca7745ed138']},\n",
       " '遨游酒店信息技术(深圳)有限责任公司': {'compIds': ['9469266'],\n",
       "  'key': ['产品经理'],\n",
       "  'init': ['-1'],\n",
       "  'searchType': ['1'],\n",
       "  'headckid': ['7a115a2bab7b46bd'],\n",
       "  'flushckid': ['1'],\n",
       "  'fromSearchBtn': ['2'],\n",
       "  'sortFlag': ['15'],\n",
       "  'ckid': ['7a115a2bab7b46bd'],\n",
       "  'siTag': ['bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw'],\n",
       "  'd_sfrom': ['search_prime'],\n",
       "  'd_ckId': ['2034a31bfcfa807d59b3bca7745ed138'],\n",
       "  'd_curPage': ['0'],\n",
       "  'd_pageSize': ['40'],\n",
       "  'd_headId': ['2034a31bfcfa807d59b3bca7745ed138']},\n",
       " 'Oracle甲骨文': {'compIds': ['2638985'],\n",
       "  'key': ['产品经理'],\n",
       "  'init': ['-1'],\n",
       "  'searchType': ['1'],\n",
       "  'headckid': ['7a115a2bab7b46bd'],\n",
       "  'flushckid': ['1'],\n",
       "  'fromSearchBtn': ['2'],\n",
       "  'sortFlag': ['15'],\n",
       "  'ckid': ['7a115a2bab7b46bd'],\n",
       "  'siTag': ['bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw'],\n",
       "  'd_sfrom': ['search_prime'],\n",
       "  'd_ckId': ['2034a31bfcfa807d59b3bca7745ed138'],\n",
       "  'd_curPage': ['0'],\n",
       "  'd_pageSize': ['40'],\n",
       "  'd_headId': ['2034a31bfcfa807d59b3bca7745ed138']},\n",
       " '北京快手科技有限公司': {'compIds': ['8605497'],\n",
       "  'key': ['产品经理'],\n",
       "  'init': ['-1'],\n",
       "  'searchType': ['1'],\n",
       "  'headckid': ['7a115a2bab7b46bd'],\n",
       "  'flushckid': ['1'],\n",
       "  'fromSearchBtn': ['2'],\n",
       "  'sortFlag': ['15'],\n",
       "  'ckid': ['7a115a2bab7b46bd'],\n",
       "  'siTag': ['bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw'],\n",
       "  'd_sfrom': ['search_prime'],\n",
       "  'd_ckId': ['2034a31bfcfa807d59b3bca7745ed138'],\n",
       "  'd_curPage': ['0'],\n",
       "  'd_pageSize': ['40'],\n",
       "  'd_headId': ['2034a31bfcfa807d59b3bca7745ed138']},\n",
       " '车好多集团': {'compIds': ['8621471'],\n",
       "  'key': ['产品经理'],\n",
       "  'init': ['-1'],\n",
       "  'searchType': ['1'],\n",
       "  'headckid': ['7a115a2bab7b46bd'],\n",
       "  'flushckid': ['1'],\n",
       "  'fromSearchBtn': ['2'],\n",
       "  'sortFlag': ['15'],\n",
       "  'ckid': ['7a115a2bab7b46bd'],\n",
       "  'siTag': ['bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw'],\n",
       "  'd_sfrom': ['search_prime'],\n",
       "  'd_ckId': ['2034a31bfcfa807d59b3bca7745ed138'],\n",
       "  'd_curPage': ['0'],\n",
       "  'd_pageSize': ['40'],\n",
       "  'd_headId': ['2034a31bfcfa807d59b3bca7745ed138']},\n",
       " '美菜': {'compIds': ['8084886'],\n",
       "  'key': ['产品经理'],\n",
       "  'init': ['-1'],\n",
       "  'searchType': ['1'],\n",
       "  'headckid': ['7a115a2bab7b46bd'],\n",
       "  'flushckid': ['1'],\n",
       "  'fromSearchBtn': ['2'],\n",
       "  'sortFlag': ['15'],\n",
       "  'ckid': ['7a115a2bab7b46bd'],\n",
       "  'siTag': ['bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw'],\n",
       "  'd_sfrom': ['search_prime'],\n",
       "  'd_ckId': ['2034a31bfcfa807d59b3bca7745ed138'],\n",
       "  'd_curPage': ['0'],\n",
       "  'd_pageSize': ['40'],\n",
       "  'd_headId': ['2034a31bfcfa807d59b3bca7745ed138']},\n",
       " '网易集团': {'compIds': ['5964833'],\n",
       "  'key': ['产品经理'],\n",
       "  'init': ['-1'],\n",
       "  'searchType': ['1'],\n",
       "  'headckid': ['7a115a2bab7b46bd'],\n",
       "  'flushckid': ['1'],\n",
       "  'fromSearchBtn': ['2'],\n",
       "  'sortFlag': ['15'],\n",
       "  'ckid': ['7a115a2bab7b46bd'],\n",
       "  'siTag': ['bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw'],\n",
       "  'd_sfrom': ['search_prime'],\n",
       "  'd_ckId': ['2034a31bfcfa807d59b3bca7745ed138'],\n",
       "  'd_curPage': ['0'],\n",
       "  'd_pageSize': ['40'],\n",
       "  'd_headId': ['2034a31bfcfa807d59b3bca7745ed138']},\n",
       " '贝壳找房(北京)科技有限公司': {'compIds': ['8461883'],\n",
       "  'key': ['产品经理'],\n",
       "  'init': ['-1'],\n",
       "  'searchType': ['1'],\n",
       "  'headckid': ['7a115a2bab7b46bd'],\n",
       "  'flushckid': ['1'],\n",
       "  'fromSearchBtn': ['2'],\n",
       "  'sortFlag': ['15'],\n",
       "  'ckid': ['7a115a2bab7b46bd'],\n",
       "  'siTag': ['bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw'],\n",
       "  'd_sfrom': ['search_prime'],\n",
       "  'd_ckId': ['2034a31bfcfa807d59b3bca7745ed138'],\n",
       "  'd_curPage': ['0'],\n",
       "  'd_pageSize': ['40'],\n",
       "  'd_headId': ['2034a31bfcfa807d59b3bca7745ed138']},\n",
       " '北京字节跳动网络技术有限公司': {'compIds': ['9630160'],\n",
       "  'key': ['产品经理'],\n",
       "  'init': ['-1'],\n",
       "  'searchType': ['1'],\n",
       "  'headckid': ['7a115a2bab7b46bd'],\n",
       "  'flushckid': ['1'],\n",
       "  'fromSearchBtn': ['2'],\n",
       "  'sortFlag': ['15'],\n",
       "  'ckid': ['7a115a2bab7b46bd'],\n",
       "  'siTag': ['bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw'],\n",
       "  'd_sfrom': ['search_prime'],\n",
       "  'd_ckId': ['2034a31bfcfa807d59b3bca7745ed138'],\n",
       "  'd_curPage': ['0'],\n",
       "  'd_pageSize': ['40'],\n",
       "  'd_headId': ['2034a31bfcfa807d59b3bca7745ed138']},\n",
       " '天津恒程科技有限公司': {'compIds': ['10023177'],\n",
       "  'key': ['产品经理'],\n",
       "  'init': ['-1'],\n",
       "  'searchType': ['1'],\n",
       "  'headckid': ['7a115a2bab7b46bd'],\n",
       "  'flushckid': ['1'],\n",
       "  'fromSearchBtn': ['2'],\n",
       "  'sortFlag': ['15'],\n",
       "  'ckid': ['7a115a2bab7b46bd'],\n",
       "  'siTag': ['bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw'],\n",
       "  'd_sfrom': ['search_prime'],\n",
       "  'd_ckId': ['2034a31bfcfa807d59b3bca7745ed138'],\n",
       "  'd_curPage': ['0'],\n",
       "  'd_pageSize': ['40'],\n",
       "  'd_headId': ['2034a31bfcfa807d59b3bca7745ed138']},\n",
       " '猎聘招聘顾问团队': {'compIds': ['12176713'],\n",
       "  'key': ['产品经理'],\n",
       "  'init': ['-1'],\n",
       "  'searchType': ['1'],\n",
       "  'headckid': ['7a115a2bab7b46bd'],\n",
       "  'flushckid': ['1'],\n",
       "  'fromSearchBtn': ['2'],\n",
       "  'sortFlag': ['15'],\n",
       "  'ckid': ['7a115a2bab7b46bd'],\n",
       "  'siTag': ['bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw'],\n",
       "  'd_sfrom': ['search_prime'],\n",
       "  'd_ckId': ['2034a31bfcfa807d59b3bca7745ed138'],\n",
       "  'd_curPage': ['0'],\n",
       "  'd_pageSize': ['40'],\n",
       "  'd_headId': ['2034a31bfcfa807d59b3bca7745ed138']},\n",
       " '软通动力': {'compIds': ['7865459'],\n",
       "  'key': ['产品经理'],\n",
       "  'init': ['-1'],\n",
       "  'searchType': ['1'],\n",
       "  'headckid': ['7a115a2bab7b46bd'],\n",
       "  'flushckid': ['1'],\n",
       "  'fromSearchBtn': ['2'],\n",
       "  'sortFlag': ['15'],\n",
       "  'ckid': ['7a115a2bab7b46bd'],\n",
       "  'siTag': ['bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw'],\n",
       "  'd_sfrom': ['search_prime'],\n",
       "  'd_ckId': ['2034a31bfcfa807d59b3bca7745ed138'],\n",
       "  'd_curPage': ['0'],\n",
       "  'd_pageSize': ['40'],\n",
       "  'd_headId': ['2034a31bfcfa807d59b3bca7745ed138']},\n",
       " '深圳依时货拉拉科技有限公司': {'compIds': ['9142549'],\n",
       "  'key': ['产品经理'],\n",
       "  'init': ['-1'],\n",
       "  'searchType': ['1'],\n",
       "  'headckid': ['7a115a2bab7b46bd'],\n",
       "  'flushckid': ['1'],\n",
       "  'fromSearchBtn': ['2'],\n",
       "  'sortFlag': ['15'],\n",
       "  'ckid': ['7a115a2bab7b46bd'],\n",
       "  'siTag': ['bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw'],\n",
       "  'd_sfrom': ['search_prime'],\n",
       "  'd_ckId': ['2034a31bfcfa807d59b3bca7745ed138'],\n",
       "  'd_curPage': ['0'],\n",
       "  'd_pageSize': ['40'],\n",
       "  'd_headId': ['2034a31bfcfa807d59b3bca7745ed138']},\n",
       " '唯品会(中国)': {'compIds': ['2020322'],\n",
       "  'key': ['产品经理'],\n",
       "  'init': ['-1'],\n",
       "  'searchType': ['1'],\n",
       "  'headckid': ['7a115a2bab7b46bd'],\n",
       "  'flushckid': ['1'],\n",
       "  'fromSearchBtn': ['2'],\n",
       "  'sortFlag': ['15'],\n",
       "  'ckid': ['7a115a2bab7b46bd'],\n",
       "  'siTag': ['bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw'],\n",
       "  'd_sfrom': ['search_prime'],\n",
       "  'd_ckId': ['2034a31bfcfa807d59b3bca7745ed138'],\n",
       "  'd_curPage': ['0'],\n",
       "  'd_pageSize': ['40'],\n",
       "  'd_headId': ['2034a31bfcfa807d59b3bca7745ed138']},\n",
       " 'OPPO移动通信': {'compIds': ['3922321'],\n",
       "  'key': ['产品经理'],\n",
       "  'init': ['-1'],\n",
       "  'searchType': ['1'],\n",
       "  'headckid': ['7a115a2bab7b46bd'],\n",
       "  'flushckid': ['1'],\n",
       "  'fromSearchBtn': ['2'],\n",
       "  'sortFlag': ['15'],\n",
       "  'ckid': ['7a115a2bab7b46bd'],\n",
       "  'siTag': ['bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw'],\n",
       "  'd_sfrom': ['search_prime'],\n",
       "  'd_ckId': ['2034a31bfcfa807d59b3bca7745ed138'],\n",
       "  'd_curPage': ['0'],\n",
       "  'd_pageSize': ['40'],\n",
       "  'd_headId': ['2034a31bfcfa807d59b3bca7745ed138']},\n",
       " '深圳平安综合金融服务有限公司': {'compIds': ['7956861'],\n",
       "  'key': ['产品经理'],\n",
       "  'init': ['-1'],\n",
       "  'searchType': ['1'],\n",
       "  'headckid': ['7a115a2bab7b46bd'],\n",
       "  'flushckid': ['1'],\n",
       "  'fromSearchBtn': ['2'],\n",
       "  'sortFlag': ['15'],\n",
       "  'ckid': ['7a115a2bab7b46bd'],\n",
       "  'siTag': ['bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw'],\n",
       "  'd_sfrom': ['search_prime'],\n",
       "  'd_ckId': ['2034a31bfcfa807d59b3bca7745ed138'],\n",
       "  'd_curPage': ['0'],\n",
       "  'd_pageSize': ['40'],\n",
       "  'd_headId': ['2034a31bfcfa807d59b3bca7745ed138']}}"
      ]
     },
     "execution_count": 161,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "from requests_html import HTMLSession\n",
    "from urllib.parse import urlparse, parse_qs\n",
    "session =HTMLSession()\n",
    "url=\"https://www.liepin.com/zhaopin/?industries=&subIndustry=&dqs=&salary=&jobKind=&pubTime=&compkind=&compscale=&industryType=&searchType=1&clean_condition=&isAnalysis=&init=1&sortFlag=15&flushckid=0&fromSearchBtn=1&headckid=a98aae475f67d6d3&d_headId=f46aad599fa2d37a4837e240451ca080&d_ckId=f46aad599fa2d37a4837e240451ca080&d_sfrom=search_unknown&d_curPage=0&d_pageSize=40&siTag=1B2M2Y8AsgTpgAmY7PhCfg%7EfA9rXquZc5IkJpXC-Ycixw&key=%E6%95%B0%E6%8D%AE%E5%88%86%E6%9E%90%E5%B8%88\"\n",
    "r=session.get(url)\n",
    "指定公司url=r.html.xpath(\"//dd[@class='comp-list']/ul[@class='clearfix']/li/a\")\n",
    "指定公司url\n",
    "公司字典={a.xpath(\"a/span/text()\")[0]:a.xpath(\"a/@href\")[0]for a in 指定公司url}\n",
    "公司字典\n",
    "href_列表 = [x.xpath('a/@href')[0] for x in 指定公司url]\n",
    "href_列表\n",
    "#分解url\n",
    "\n",
    "df= pd.DataFrame([urlparse(x) for x in href_列表])\n",
    "df.nunique()\n",
    "df_qs=pd.DataFrame([{k:v[0]for k,v in parse_qs(x).items()}for x in df['query']])\n",
    "display(df_qs)\n",
    "df_qs.nunique()\n",
    "#compIds 不同\n",
    "#取一例做参数模板\n",
    "def 参数拆解(url):\n",
    "    sixpart=urlparse(url)\n",
    "    out=parse_qs(sixpart.query)\n",
    "    return out\n",
    "\n",
    "参数模板=参数拆解(href_列表[0])\n",
    "参数模板\n",
    "def 参数调整(key,compIds):\n",
    "    参数=参数模板.copy()\n",
    "    参数['key']=key\n",
    "    参数['compIds']=compIds\n",
    "    return 参数\n",
    "公司代号字典={k:参数拆解(v)['compIds'][0]for k,v in 公司字典.items()}\n",
    "公司代号字典\n",
    "\n",
    "修改关键词={k:参数调整(compIds=[v],key=['产品经理'])for k,v in 公司代号字典.items()}\n",
    "修改关键词"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 164,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "{'字节跳动': '7863078',\n",
       " '腾讯': '7983148',\n",
       " '便利蜂': '8983822',\n",
       " '滴滴': '8076624',\n",
       " '饿了么': '2778803',\n",
       " '京东商城': '9747025',\n",
       " '58同城': '591850',\n",
       " '北京国富如荷网络科技有限公司': '8089425',\n",
       " '美团点评': '2036768',\n",
       " 'vivo': '4787049',\n",
       " '岩心科技': '8640905',\n",
       " '阿里巴巴': '1072424',\n",
       " '小米': '2174886',\n",
       " '上海寻梦信息技术有限公司': '8537928',\n",
       " '携程': '182339',\n",
       " '资采信息': '8830801',\n",
       " '捷信消费金融有限公司': '8660469',\n",
       " '亚信科技': '2399664',\n",
       " '思爱普': '8899712',\n",
       " 'Baidu': '884492',\n",
       " '遨游酒店信息技术(深圳)有限责任公司': '9469266',\n",
       " 'Oracle甲骨文': '2638985',\n",
       " '北京快手科技有限公司': '8605497',\n",
       " '车好多集团': '8621471',\n",
       " '美菜': '8084886',\n",
       " '网易集团': '5964833',\n",
       " '贝壳找房(北京)科技有限公司': '8461883',\n",
       " '北京字节跳动网络技术有限公司': '9630160',\n",
       " '天津恒程科技有限公司': '10023177',\n",
       " '猎聘招聘顾问团队': '12176713',\n",
       " '软通动力': '7865459',\n",
       " '深圳依时货拉拉科技有限公司': '9142549',\n",
       " '唯品会(中国)': '2020322',\n",
       " 'OPPO移动通信': '3922321',\n",
       " '深圳平安综合金融服务有限公司': '7956861'}"
      ]
     },
     "execution_count": 164,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "公司代号字典"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## 尝试一个公司多个搜索关键词翻页搜索"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 167,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "用户体验 10\n",
      "UX 10\n",
      "产品需求 10\n",
      "PRD 10\n"
     ]
    },
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>index</th>\n",
       "      <th>edu</th>\n",
       "      <th>经验</th>\n",
       "      <th>薪水</th>\n",
       "      <th>时间</th>\n",
       "      <th>职称</th>\n",
       "      <th>公司地点</th>\n",
       "      <th>公司名称</th>\n",
       "      <th>链结</th>\n",
       "      <th>公司URL</th>\n",
       "      <th>keyword</th>\n",
       "      <th>curPage</th>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>序</th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>0</td>\n",
       "      <td>本科及以上</td>\n",
       "      <td>5-10年</td>\n",
       "      <td>面议</td>\n",
       "      <td>2020年04月23日</td>\n",
       "      <td>15571-高级用户体验设计师（深圳）</td>\n",
       "      <td>深圳</td>\n",
       "      <td>腾讯</td>\n",
       "      <td>https://www.liepin.com/job/1927273491.shtml</td>\n",
       "      <td>https://www.liepin.com/company/7983148/</td>\n",
       "      <td>用户体验</td>\n",
       "      <td>0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td>1</td>\n",
       "      <td>本科及以上</td>\n",
       "      <td>3-5年</td>\n",
       "      <td>面议</td>\n",
       "      <td>2020年04月23日</td>\n",
       "      <td>30359-欧拉-用户体验设计师（深圳）</td>\n",
       "      <td>深圳</td>\n",
       "      <td>腾讯</td>\n",
       "      <td>https://www.liepin.com/job/1926238757.shtml</td>\n",
       "      <td>https://www.liepin.com/company/7983148/</td>\n",
       "      <td>用户体验</td>\n",
       "      <td>0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>2</td>\n",
       "      <td>本科及以上</td>\n",
       "      <td>3-5年</td>\n",
       "      <td>面议</td>\n",
       "      <td>2020年04月23日</td>\n",
       "      <td>EC-交互设计师</td>\n",
       "      <td>深圳</td>\n",
       "      <td>腾讯</td>\n",
       "      <td>https://www.liepin.com/job/1927273669.shtml</td>\n",
       "      <td>https://www.liepin.com/company/7983148/</td>\n",
       "      <td>用户体验</td>\n",
       "      <td>0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>3</th>\n",
       "      <td>3</td>\n",
       "      <td>本科及以上</td>\n",
       "      <td>3-5年</td>\n",
       "      <td>面议</td>\n",
       "      <td>2020年04月23日</td>\n",
       "      <td>18425-交互设计师</td>\n",
       "      <td>深圳</td>\n",
       "      <td>腾讯</td>\n",
       "      <td>https://www.liepin.com/job/1926713509.shtml</td>\n",
       "      <td>https://www.liepin.com/company/7983148/</td>\n",
       "      <td>用户体验</td>\n",
       "      <td>0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>4</th>\n",
       "      <td>4</td>\n",
       "      <td>本科及以上</td>\n",
       "      <td>3-5年</td>\n",
       "      <td>面议</td>\n",
       "      <td>2020年04月23日</td>\n",
       "      <td>22989-高级交互设计师</td>\n",
       "      <td>深圳</td>\n",
       "      <td>腾讯</td>\n",
       "      <td>https://www.liepin.com/job/1927326515.shtml</td>\n",
       "      <td>https://www.liepin.com/company/7983148/</td>\n",
       "      <td>用户体验</td>\n",
       "      <td>0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>...</th>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>939</th>\n",
       "      <td>13</td>\n",
       "      <td>本科及以上</td>\n",
       "      <td>3-5年</td>\n",
       "      <td>面议</td>\n",
       "      <td>2019年10月15日</td>\n",
       "      <td>25925-用户平台权益产品策划（深圳）</td>\n",
       "      <td>深圳</td>\n",
       "      <td>腾讯</td>\n",
       "      <td>https://www.liepin.com/job/1920932363.shtml</td>\n",
       "      <td>https://www.liepin.com/company/7983148/</td>\n",
       "      <td>PRD</td>\n",
       "      <td>0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>940</th>\n",
       "      <td>14</td>\n",
       "      <td>本科及以上</td>\n",
       "      <td>5-10年</td>\n",
       "      <td>面议</td>\n",
       "      <td>2019年10月15日</td>\n",
       "      <td>19332-产品运营经理（客户运营）（上海）</td>\n",
       "      <td>上海</td>\n",
       "      <td>腾讯</td>\n",
       "      <td>https://www.liepin.com/job/1920923629.shtml</td>\n",
       "      <td>https://www.liepin.com/company/7983148/</td>\n",
       "      <td>PRD</td>\n",
       "      <td>0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>941</th>\n",
       "      <td>15</td>\n",
       "      <td>本科及以上</td>\n",
       "      <td>5-10年</td>\n",
       "      <td>面议</td>\n",
       "      <td>2019年10月15日</td>\n",
       "      <td>22989-大数据产品经理（成都）</td>\n",
       "      <td>成都</td>\n",
       "      <td>腾讯</td>\n",
       "      <td>https://www.liepin.com/job/1916851781.shtml</td>\n",
       "      <td>https://www.liepin.com/company/7983148/</td>\n",
       "      <td>PRD</td>\n",
       "      <td>0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>942</th>\n",
       "      <td>16</td>\n",
       "      <td>本科及以上</td>\n",
       "      <td>3-5年</td>\n",
       "      <td>面议</td>\n",
       "      <td>2019年10月15日</td>\n",
       "      <td>25924-数据分析高级产品经理BI（深圳）</td>\n",
       "      <td>深圳</td>\n",
       "      <td>腾讯</td>\n",
       "      <td>https://www.liepin.com/job/1915346203.shtml</td>\n",
       "      <td>https://www.liepin.com/company/7983148/</td>\n",
       "      <td>PRD</td>\n",
       "      <td>0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>943</th>\n",
       "      <td>17</td>\n",
       "      <td>本科及以上</td>\n",
       "      <td>5-10年</td>\n",
       "      <td>面议</td>\n",
       "      <td>2019年10月15日</td>\n",
       "      <td>MIG16-自动驾驶产品经理(北京)</td>\n",
       "      <td>北京</td>\n",
       "      <td>腾讯</td>\n",
       "      <td>https://www.liepin.com/job/1913395126.shtml</td>\n",
       "      <td>https://www.liepin.com/company/7983148/</td>\n",
       "      <td>PRD</td>\n",
       "      <td>0</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "<p>944 rows × 12 columns</p>\n",
       "</div>"
      ],
      "text/plain": [
       "     index    edu     经验  薪水           时间                      职称 公司地点 公司名称  \\\n",
       "序                                                                             \n",
       "0        0  本科及以上  5-10年  面议  2020年04月23日     15571-高级用户体验设计师（深圳）   深圳   腾讯   \n",
       "1        1  本科及以上   3-5年  面议  2020年04月23日    30359-欧拉-用户体验设计师（深圳）   深圳   腾讯   \n",
       "2        2  本科及以上   3-5年  面议  2020年04月23日                EC-交互设计师   深圳   腾讯   \n",
       "3        3  本科及以上   3-5年  面议  2020年04月23日             18425-交互设计师   深圳   腾讯   \n",
       "4        4  本科及以上   3-5年  面议  2020年04月23日           22989-高级交互设计师   深圳   腾讯   \n",
       "..     ...    ...    ...  ..          ...                     ...  ...  ...   \n",
       "939     13  本科及以上   3-5年  面议  2019年10月15日    25925-用户平台权益产品策划（深圳）   深圳   腾讯   \n",
       "940     14  本科及以上  5-10年  面议  2019年10月15日  19332-产品运营经理（客户运营）（上海）   上海   腾讯   \n",
       "941     15  本科及以上  5-10年  面议  2019年10月15日       22989-大数据产品经理（成都）   成都   腾讯   \n",
       "942     16  本科及以上   3-5年  面议  2019年10月15日  25924-数据分析高级产品经理BI（深圳）   深圳   腾讯   \n",
       "943     17  本科及以上  5-10年  面议  2019年10月15日      MIG16-自动驾驶产品经理(北京)   北京   腾讯   \n",
       "\n",
       "                                              链结  \\\n",
       "序                                                  \n",
       "0    https://www.liepin.com/job/1927273491.shtml   \n",
       "1    https://www.liepin.com/job/1926238757.shtml   \n",
       "2    https://www.liepin.com/job/1927273669.shtml   \n",
       "3    https://www.liepin.com/job/1926713509.shtml   \n",
       "4    https://www.liepin.com/job/1927326515.shtml   \n",
       "..                                           ...   \n",
       "939  https://www.liepin.com/job/1920932363.shtml   \n",
       "940  https://www.liepin.com/job/1920923629.shtml   \n",
       "941  https://www.liepin.com/job/1916851781.shtml   \n",
       "942  https://www.liepin.com/job/1915346203.shtml   \n",
       "943  https://www.liepin.com/job/1913395126.shtml   \n",
       "\n",
       "                                       公司URL keyword  curPage  \n",
       "序                                                              \n",
       "0    https://www.liepin.com/company/7983148/    用户体验        0  \n",
       "1    https://www.liepin.com/company/7983148/    用户体验        0  \n",
       "2    https://www.liepin.com/company/7983148/    用户体验        0  \n",
       "3    https://www.liepin.com/company/7983148/    用户体验        0  \n",
       "4    https://www.liepin.com/company/7983148/    用户体验        0  \n",
       "..                                       ...     ...      ...  \n",
       "939  https://www.liepin.com/company/7983148/     PRD        0  \n",
       "940  https://www.liepin.com/company/7983148/     PRD        0  \n",
       "941  https://www.liepin.com/company/7983148/     PRD        0  \n",
       "942  https://www.liepin.com/company/7983148/     PRD        0  \n",
       "943  https://www.liepin.com/company/7983148/     PRD        0  \n",
       "\n",
       "[944 rows x 12 columns]"
      ]
     },
     "execution_count": 167,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "import time\n",
    "from random import random\n",
    "from requests_html import HTMLSession\n",
    "session =HTMLSession()\n",
    "url=\"https://www.liepin.com/zhaopin/\"\n",
    "r=session.get(url)\n",
    "keywords = ['用户体验','UX','产品需求','PRD']\n",
    "list_df=list()\n",
    "for key in keywords:\n",
    "    href_列表 = [x.xpath('//@href')[0] for x in r.html.xpath(xpath_翻页a)]\n",
    "    df = pd.DataFrame([ urlparse(x) for x in href_列表])\n",
    "    df_qs = pd.DataFrame([{k:v[0] for k,v in parse_qs(x).items()} for x in df['query'] ])\n",
    "    df_qs = df_qs.assign (curPage_int=df_qs.curPage.astype(int)) # 变成整数\n",
    "    长度 = df_qs.curPage_int.max()+1\n",
    "    指定公司_关键词_翻页参数={i:翻页_参数调整(key=[key],compIds=['7983148'],curPage = [i])\n",
    "                                   for i in  range(0,长度)\n",
    "                                  } \n",
    "    \n",
    "    #print (参数_keyword_X_curPage)\n",
    "    print (key,长度)\n",
    "    for k,v in  指定公司_关键词_翻页参数.items():\n",
    "        payload = v\n",
    "        df = requests_liepin( url, params = payload)\n",
    "        time.sleep(1+4*random())  #放慢脚步 3-7秒, 平均约5秒\n",
    "        ## 备份\n",
    "#         df.to_csv(\"20春_Web数据挖掘_week04_liepin_{key}_{k}.tsv\"\\\n",
    "#                   .format(key=key, k=k), sep=\"\\t\", encoding=\"utf8\")\n",
    "        \n",
    "        df = df.assign (keyword = key)  # 区分  keyword    \n",
    "        df = df.assign (curPage = k)  # 区分  curPage   \n",
    "        \n",
    "        list_df.append(df)\n",
    "        \n",
    "df_多个关键词爬取 = pd.concat(list_df).reset_index()\n",
    "df_多个关键词爬取.index.name = '序'\n",
    "df_多个关键词爬取\n",
    "#df_all.to_excel(\"20春_Web数据挖掘_week04_liepin_翻页_4.xlsx\",\\\n",
    "#                sheet_name=\"_\".join(keywords))\n"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "##  多个公司多个关键词搜索"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 168,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "数据分析师 7863078 10\n",
      "产品经理 7863078 10\n",
      "数据分析师 7983148 10\n",
      "产品经理 7983148 10\n",
      "数据分析师 8983822 10\n",
      "产品经理 8983822 10\n",
      "数据分析师 8076624 10\n",
      "产品经理 8076624 10\n",
      "数据分析师 2778803 10\n",
      "产品经理 2778803 10\n",
      "数据分析师 9747025 10\n",
      "产品经理 9747025 10\n",
      "数据分析师 591850 10\n",
      "产品经理 591850 10\n",
      "数据分析师 8089425 10\n",
      "产品经理 8089425 10\n",
      "数据分析师 2036768 10\n",
      "产品经理 2036768 10\n",
      "数据分析师 4787049 10\n",
      "产品经理 4787049 10\n",
      "数据分析师 8640905 10\n",
      "产品经理 8640905 10\n",
      "数据分析师 1072424 10\n",
      "产品经理 1072424 10\n",
      "数据分析师 2174886 10\n",
      "产品经理 2174886 10\n",
      "数据分析师 8537928 10\n",
      "产品经理 8537928 10\n",
      "数据分析师 182339 10\n",
      "产品经理 182339 10\n",
      "数据分析师 8830801 10\n",
      "产品经理 8830801 10\n",
      "数据分析师 8660469 10\n",
      "产品经理 8660469 10\n",
      "数据分析师 2399664 10\n",
      "产品经理 2399664 10\n",
      "数据分析师 8899712 10\n",
      "产品经理 8899712 10\n",
      "数据分析师 884492 10\n",
      "产品经理 884492 10\n",
      "数据分析师 9469266 10\n",
      "产品经理 9469266 10\n",
      "数据分析师 2638985 10\n",
      "产品经理 2638985 10\n",
      "数据分析师 8605497 10\n",
      "产品经理 8605497 10\n",
      "数据分析师 8621471 10\n",
      "产品经理 8621471 10\n",
      "数据分析师 8084886 10\n",
      "产品经理 8084886 10\n",
      "数据分析师 5964833 10\n",
      "产品经理 5964833 10\n",
      "数据分析师 8461883 10\n",
      "产品经理 8461883 10\n",
      "数据分析师 9630160 10\n",
      "产品经理 9630160 10\n",
      "数据分析师 10023177 10\n",
      "产品经理 10023177 10\n",
      "数据分析师 12176713 10\n",
      "产品经理 12176713 10\n",
      "数据分析师 7865459 10\n",
      "产品经理 7865459 10\n",
      "数据分析师 9142549 10\n",
      "产品经理 9142549 10\n",
      "数据分析师 2020322 10\n",
      "产品经理 2020322 10\n",
      "数据分析师 3922321 10\n",
      "产品经理 3922321 10\n",
      "数据分析师 7956861 10\n",
      "产品经理 7956861 10\n"
     ]
    },
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>index</th>\n",
       "      <th>edu</th>\n",
       "      <th>经验</th>\n",
       "      <th>薪水</th>\n",
       "      <th>时间</th>\n",
       "      <th>职称</th>\n",
       "      <th>公司地点</th>\n",
       "      <th>公司名称</th>\n",
       "      <th>链结</th>\n",
       "      <th>公司URL</th>\n",
       "      <th>keyword</th>\n",
       "      <th>curPage</th>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>序</th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>0</td>\n",
       "      <td>本科及以上</td>\n",
       "      <td>1-3年</td>\n",
       "      <td>面议</td>\n",
       "      <td>2020年04月23日</td>\n",
       "      <td>游戏高级数据分析师</td>\n",
       "      <td>广州-海珠区</td>\n",
       "      <td>字节跳动</td>\n",
       "      <td>https://www.liepin.com/job/1927675187.shtml</td>\n",
       "      <td>https://www.liepin.com/company/7863078/</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td>1</td>\n",
       "      <td>本科及以上</td>\n",
       "      <td>1-3年</td>\n",
       "      <td>面议</td>\n",
       "      <td>2020年04月23日</td>\n",
       "      <td>高级数据分析师-教育</td>\n",
       "      <td>上海-闵行区</td>\n",
       "      <td>字节跳动</td>\n",
       "      <td>https://www.liepin.com/job/1927675183.shtml</td>\n",
       "      <td>https://www.liepin.com/company/7863078/</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>2</td>\n",
       "      <td>本科及以上</td>\n",
       "      <td>1-3年</td>\n",
       "      <td>面议</td>\n",
       "      <td>2020年04月23日</td>\n",
       "      <td>高级数据分析师-音乐</td>\n",
       "      <td>上海-闵行区</td>\n",
       "      <td>字节跳动</td>\n",
       "      <td>https://www.liepin.com/job/1927675181.shtml</td>\n",
       "      <td>https://www.liepin.com/company/7863078/</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>3</th>\n",
       "      <td>3</td>\n",
       "      <td>本科及以上</td>\n",
       "      <td>经验不限</td>\n",
       "      <td>面议</td>\n",
       "      <td>2020年04月23日</td>\n",
       "      <td>网络数据分析师</td>\n",
       "      <td></td>\n",
       "      <td>字节跳动</td>\n",
       "      <td>https://www.liepin.com/job/1927674999.shtml</td>\n",
       "      <td>https://www.liepin.com/company/7863078/</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>4</th>\n",
       "      <td>4</td>\n",
       "      <td>本科及以上</td>\n",
       "      <td>经验不限</td>\n",
       "      <td>面议</td>\n",
       "      <td>2020年04月23日</td>\n",
       "      <td>游戏业务中台数据分析师</td>\n",
       "      <td>深圳-南山区</td>\n",
       "      <td>字节跳动</td>\n",
       "      <td>https://www.liepin.com/job/1927627993.shtml</td>\n",
       "      <td>https://www.liepin.com/company/7863078/</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>...</th>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>5546</th>\n",
       "      <td>29</td>\n",
       "      <td>学历不限</td>\n",
       "      <td>3-5年</td>\n",
       "      <td>面议</td>\n",
       "      <td>2020年03月22日</td>\n",
       "      <td>12313T-数据挖掘</td>\n",
       "      <td>深圳</td>\n",
       "      <td>深圳平安综合金融服务有限公司</td>\n",
       "      <td>https://www.liepin.com/job/1926401053.shtml</td>\n",
       "      <td>https://www.liepin.com/company/7956861/</td>\n",
       "      <td>产品经理</td>\n",
       "      <td>2</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>5547</th>\n",
       "      <td>30</td>\n",
       "      <td>统招本科</td>\n",
       "      <td>3-5年</td>\n",
       "      <td>15-30k·17薪</td>\n",
       "      <td>2020年01月16日</td>\n",
       "      <td>12310L-设计</td>\n",
       "      <td>深圳</td>\n",
       "      <td>深圳平安综合金融服务有限公司</td>\n",
       "      <td>https://www.liepin.com/job/1925809859.shtml</td>\n",
       "      <td>https://www.liepin.com/company/7956861/</td>\n",
       "      <td>产品经理</td>\n",
       "      <td>2</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>5548</th>\n",
       "      <td>31</td>\n",
       "      <td>本科及以上</td>\n",
       "      <td>1-3年</td>\n",
       "      <td>面议</td>\n",
       "      <td>2019年10月16日</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>上海</td>\n",
       "      <td>深圳平安综合金融服务有限公司</td>\n",
       "      <td>https://www.liepin.com/job/1923278297.shtml</td>\n",
       "      <td>https://www.liepin.com/company/7956861/</td>\n",
       "      <td>产品经理</td>\n",
       "      <td>2</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>5549</th>\n",
       "      <td>32</td>\n",
       "      <td>学历不限</td>\n",
       "      <td>1-3年</td>\n",
       "      <td>面议</td>\n",
       "      <td>2019年09月29日</td>\n",
       "      <td>1221GQ-产品运营岗</td>\n",
       "      <td>上海</td>\n",
       "      <td>深圳平安综合金融服务有限公司</td>\n",
       "      <td>https://www.liepin.com/job/1923837679.shtml</td>\n",
       "      <td>https://www.liepin.com/company/7956861/</td>\n",
       "      <td>产品经理</td>\n",
       "      <td>2</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>5550</th>\n",
       "      <td>33</td>\n",
       "      <td>本科及以上</td>\n",
       "      <td>3-5年</td>\n",
       "      <td>20-25k·12薪</td>\n",
       "      <td>2019年03月02日</td>\n",
       "      <td>IT岗位</td>\n",
       "      <td>深圳-益田村</td>\n",
       "      <td>深圳平安综合金融服务有限公司</td>\n",
       "      <td>https://www.liepin.com/job/1918042897.shtml</td>\n",
       "      <td>https://www.liepin.com/company/7956861/</td>\n",
       "      <td>产品经理</td>\n",
       "      <td>2</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "<p>5551 rows × 12 columns</p>\n",
       "</div>"
      ],
      "text/plain": [
       "      index    edu    经验          薪水           时间            职称    公司地点  \\\n",
       "序                                                                         \n",
       "0         0  本科及以上  1-3年          面议  2020年04月23日     游戏高级数据分析师  广州-海珠区   \n",
       "1         1  本科及以上  1-3年          面议  2020年04月23日    高级数据分析师-教育  上海-闵行区   \n",
       "2         2  本科及以上  1-3年          面议  2020年04月23日    高级数据分析师-音乐  上海-闵行区   \n",
       "3         3  本科及以上  经验不限          面议  2020年04月23日       网络数据分析师           \n",
       "4         4  本科及以上  经验不限          面议  2020年04月23日   游戏业务中台数据分析师  深圳-南山区   \n",
       "...     ...    ...   ...         ...          ...           ...     ...   \n",
       "5546     29   学历不限  3-5年          面议  2020年03月22日   12313T-数据挖掘      深圳   \n",
       "5547     30   统招本科  3-5年  15-30k·17薪  2020年01月16日     12310L-设计      深圳   \n",
       "5548     31  本科及以上  1-3年          面议  2019年10月16日         数据分析师      上海   \n",
       "5549     32   学历不限  1-3年          面议  2019年09月29日  1221GQ-产品运营岗      上海   \n",
       "5550     33  本科及以上  3-5年  20-25k·12薪  2019年03月02日          IT岗位  深圳-益田村   \n",
       "\n",
       "                公司名称                                           链结  \\\n",
       "序                                                                   \n",
       "0               字节跳动  https://www.liepin.com/job/1927675187.shtml   \n",
       "1               字节跳动  https://www.liepin.com/job/1927675183.shtml   \n",
       "2               字节跳动  https://www.liepin.com/job/1927675181.shtml   \n",
       "3               字节跳动  https://www.liepin.com/job/1927674999.shtml   \n",
       "4               字节跳动  https://www.liepin.com/job/1927627993.shtml   \n",
       "...              ...                                          ...   \n",
       "5546  深圳平安综合金融服务有限公司  https://www.liepin.com/job/1926401053.shtml   \n",
       "5547  深圳平安综合金融服务有限公司  https://www.liepin.com/job/1925809859.shtml   \n",
       "5548  深圳平安综合金融服务有限公司  https://www.liepin.com/job/1923278297.shtml   \n",
       "5549  深圳平安综合金融服务有限公司  https://www.liepin.com/job/1923837679.shtml   \n",
       "5550  深圳平安综合金融服务有限公司  https://www.liepin.com/job/1918042897.shtml   \n",
       "\n",
       "                                        公司URL keyword  curPage  \n",
       "序                                                               \n",
       "0     https://www.liepin.com/company/7863078/   数据分析师        0  \n",
       "1     https://www.liepin.com/company/7863078/   数据分析师        0  \n",
       "2     https://www.liepin.com/company/7863078/   数据分析师        0  \n",
       "3     https://www.liepin.com/company/7863078/   数据分析师        0  \n",
       "4     https://www.liepin.com/company/7863078/   数据分析师        0  \n",
       "...                                       ...     ...      ...  \n",
       "5546  https://www.liepin.com/company/7956861/    产品经理        2  \n",
       "5547  https://www.liepin.com/company/7956861/    产品经理        2  \n",
       "5548  https://www.liepin.com/company/7956861/    产品经理        2  \n",
       "5549  https://www.liepin.com/company/7956861/    产品经理        2  \n",
       "5550  https://www.liepin.com/company/7956861/    产品经理        2  \n",
       "\n",
       "[5551 rows x 12 columns]"
      ]
     },
     "execution_count": 168,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "import time\n",
    "from random import random\n",
    "from requests_html import HTMLSession\n",
    "session =HTMLSession()\n",
    "url=\"https://www.liepin.com/zhaopin/\"\n",
    "r=session.get(url)\n",
    "keywords = ['数据分析师','产品经理']\n",
    "list_df=list()\n",
    "for number in 公司代号字典.values():\n",
    "    href_列表 = [x.xpath('//@href')[0] for x in r.html.xpath(xpath_翻页a)]\n",
    "    df = pd.DataFrame([ urlparse(x) for x in href_列表])\n",
    "    df_qs = pd.DataFrame([{k:v[0] for k,v in parse_qs(x).items()} for x in df['query'] ])\n",
    "    df_qs = df_qs.assign (curPage_int=df_qs.curPage.astype(int)) # 变成整数\n",
    "    长度 = df_qs.curPage_int.max()+1\n",
    "#     指定公司_关键词_翻页参数={i:翻页_参数调整(key=[key],compIds=[number],curPage = [i])\n",
    "#                                        for i in  range(0,长度)\n",
    "#                                       }\n",
    "#     print (key,number,长度)\n",
    "    for key in keywords:\n",
    "        指定公司_关键词_翻页参数={i:翻页_参数调整(key=[key],compIds=[number],curPage = [i])\n",
    "                                       for i in  range(0,长度)\n",
    "                                      } \n",
    "\n",
    "        #print (参数_keyword_X_curPage)\n",
    "        print (key,number,长度)\n",
    "        for k,v in  指定公司_关键词_翻页参数.items():\n",
    "            payload = v\n",
    "            df = requests_liepin( url, params = payload)\n",
    "            #time.sleep(1+4*random())  #放慢脚步 3-7秒, 平均约5秒\n",
    "            ## 备份\n",
    "#             df.to_csv(\"20春_Web数据挖掘_week07_liepin_{key}_{k}.tsv\"\\\n",
    "#                       .format(key=key, k=k), sep=\"\\t\", encoding=\"utf8\")\n",
    "\n",
    "            df = df.assign (keyword = key)  # 区分  keyword    \n",
    "            df = df.assign (curPage = k)  # 区分  curPage    \n",
    "            list_df.append(df)\n",
    "        \n",
    "df_all = pd.concat(list_df).reset_index()\n",
    "df_all.index.name = '序'\n",
    "df_all"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "# 行业爬取"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 148,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "{'互联网·游戏·软件': ['互联网/电商', '游戏产业', '计算机软件', 'IT服务'],\n",
       " '电子·通信·硬件': ['电子/芯片/半导体', '通信业', '计算机/网络设备'],\n",
       " '房地产·建筑·物业': ['房地产/建筑', '规划/设计/装潢', '房地产服务'],\n",
       " '金融': ['银行', '保险', '基金/证券/投资', '会计/审计', '信托/担保/拍卖'],\n",
       " '消费品': ['快消品', '批发零售', '服装纺织', '家具/家电', '办公设备', '奢侈品/收藏品', '珠宝/玩具/工艺品'],\n",
       " '汽车·机械·制造': ['汽车/摩托车', '机械/机电/重工', '印刷/包装/造纸', '原材料加工', '仪器/电气/自动化'],\n",
       " '制药·医疗': ['制药/生物工程', '医疗/保健/美容', '医疗器械'],\n",
       " '能源·化工·环保': ['能源/水利', '石油/化工', '采掘/冶炼/矿产', '环保', '新能源'],\n",
       " '服务·外包·中介': ['专业服务', '中介服务', '外包服务', '检测/认证', '餐饮/酒旅/服务', '文体娱乐', '租赁服务'],\n",
       " '广告·传媒·教育·文化': ['广告/市场/会展', '影视文化', '教育培训'],\n",
       " '交通·贸易·物流': ['交通/物流/运输', '贸易/进出口', '航空/航天'],\n",
       " '政府·农林牧渔': ['政务/公共服务', '农林牧渔', '其他行业']}"
      ]
     },
     "metadata": {},
     "output_type": "display_data"
    },
    {
     "data": {
      "text/plain": [
       "{'互联网/电商': '/zhaopin/?isAnalysis=&dqs=&pubTime=&salary=&compIds=&subIndustry=&industryType=industry_01&compscale=&key=%E6%95%B0%E6%8D%AE%E5%88%86%E6%9E%90%E5%B8%88&init=-1&searchType=1&headckid=aa4a3ef545437f22&flushckid=1&compkind=&fromSearchBtn=2&sortFlag=15&ckid=bce53da97cf10328&jobKind=&industries=040&clean_condition=&siTag=bFGQTbwE_AAQSb-u11jrBw%7EfA9rXquZc5IkJpXC-Ycixw&d_sfrom=search_prime&d_ckId=591ebc1760fee953b72353bace17e6cc&d_curPage=0&d_pageSize=40&d_headId=591ebc1760fee953b72353bace17e6cc',\n",
       " '游戏产业': '/zhaopin/?isAnalysis=&dqs=&pubTime=&salary=&compIds=&subIndustry=&industryType=industry_01&compscale=&key=%E6%95%B0%E6%8D%AE%E5%88%86%E6%9E%90%E5%B8%88&init=-1&searchType=1&headckid=aa4a3ef545437f22&flushckid=1&compkind=&fromSearchBtn=2&sortFlag=15&ckid=bce53da97cf10328&jobKind=&industries=420&clean_condition=&siTag=bFGQTbwE_AAQSb-u11jrBw%7EfA9rXquZc5IkJpXC-Ycixw&d_sfrom=search_prime&d_ckId=591ebc1760fee953b72353bace17e6cc&d_curPage=0&d_pageSize=40&d_headId=591ebc1760fee953b72353bace17e6cc',\n",
       " '计算机软件': '/zhaopin/?isAnalysis=&dqs=&pubTime=&salary=&compIds=&subIndustry=&industryType=industry_01&compscale=&key=%E6%95%B0%E6%8D%AE%E5%88%86%E6%9E%90%E5%B8%88&init=-1&searchType=1&headckid=aa4a3ef545437f22&flushckid=1&compkind=&fromSearchBtn=2&sortFlag=15&ckid=bce53da97cf10328&jobKind=&industries=010&clean_condition=&siTag=bFGQTbwE_AAQSb-u11jrBw%7EfA9rXquZc5IkJpXC-Ycixw&d_sfrom=search_prime&d_ckId=591ebc1760fee953b72353bace17e6cc&d_curPage=0&d_pageSize=40&d_headId=591ebc1760fee953b72353bace17e6cc',\n",
       " 'IT服务': '/zhaopin/?isAnalysis=&dqs=&pubTime=&salary=&compIds=&subIndustry=&industryType=industry_01&compscale=&key=%E6%95%B0%E6%8D%AE%E5%88%86%E6%9E%90%E5%B8%88&init=-1&searchType=1&headckid=aa4a3ef545437f22&flushckid=1&compkind=&fromSearchBtn=2&sortFlag=15&ckid=bce53da97cf10328&jobKind=&industries=030&clean_condition=&siTag=bFGQTbwE_AAQSb-u11jrBw%7EfA9rXquZc5IkJpXC-Ycixw&d_sfrom=search_prime&d_ckId=591ebc1760fee953b72353bace17e6cc&d_curPage=0&d_pageSize=40&d_headId=591ebc1760fee953b72353bace17e6cc',\n",
       " '电子/芯片/半导体': '/zhaopin/?isAnalysis=&dqs=&pubTime=&salary=&compIds=&subIndustry=&industryType=industry_02&compscale=&key=%E6%95%B0%E6%8D%AE%E5%88%86%E6%9E%90%E5%B8%88&init=-1&searchType=1&headckid=aa4a3ef545437f22&flushckid=1&compkind=&fromSearchBtn=2&sortFlag=15&ckid=bce53da97cf10328&jobKind=&industries=050&clean_condition=&siTag=bFGQTbwE_AAQSb-u11jrBw%7EfA9rXquZc5IkJpXC-Ycixw&d_sfrom=search_prime&d_ckId=591ebc1760fee953b72353bace17e6cc&d_curPage=0&d_pageSize=40&d_headId=591ebc1760fee953b72353bace17e6cc',\n",
       " '通信业': '/zhaopin/?isAnalysis=&dqs=&pubTime=&salary=&compIds=&subIndustry=&industryType=industry_02&compscale=&key=%E6%95%B0%E6%8D%AE%E5%88%86%E6%9E%90%E5%B8%88&init=-1&searchType=1&headckid=aa4a3ef545437f22&flushckid=1&compkind=&fromSearchBtn=2&sortFlag=15&ckid=bce53da97cf10328&jobKind=&industries=060&clean_condition=&siTag=bFGQTbwE_AAQSb-u11jrBw%7EfA9rXquZc5IkJpXC-Ycixw&d_sfrom=search_prime&d_ckId=591ebc1760fee953b72353bace17e6cc&d_curPage=0&d_pageSize=40&d_headId=591ebc1760fee953b72353bace17e6cc',\n",
       " '计算机/网络设备': '/zhaopin/?isAnalysis=&dqs=&pubTime=&salary=&compIds=&subIndustry=&industryType=industry_02&compscale=&key=%E6%95%B0%E6%8D%AE%E5%88%86%E6%9E%90%E5%B8%88&init=-1&searchType=1&headckid=aa4a3ef545437f22&flushckid=1&compkind=&fromSearchBtn=2&sortFlag=15&ckid=bce53da97cf10328&jobKind=&industries=020&clean_condition=&siTag=bFGQTbwE_AAQSb-u11jrBw%7EfA9rXquZc5IkJpXC-Ycixw&d_sfrom=search_prime&d_ckId=591ebc1760fee953b72353bace17e6cc&d_curPage=0&d_pageSize=40&d_headId=591ebc1760fee953b72353bace17e6cc',\n",
       " '房地产/建筑': '/zhaopin/?isAnalysis=&dqs=&pubTime=&salary=&compIds=&subIndustry=&industryType=industry_03&compscale=&key=%E6%95%B0%E6%8D%AE%E5%88%86%E6%9E%90%E5%B8%88&init=-1&searchType=1&headckid=aa4a3ef545437f22&flushckid=1&compkind=&fromSearchBtn=2&sortFlag=15&ckid=bce53da97cf10328&jobKind=&industries=080&clean_condition=&siTag=bFGQTbwE_AAQSb-u11jrBw%7EfA9rXquZc5IkJpXC-Ycixw&d_sfrom=search_prime&d_ckId=591ebc1760fee953b72353bace17e6cc&d_curPage=0&d_pageSize=40&d_headId=591ebc1760fee953b72353bace17e6cc',\n",
       " '规划/设计/装潢': '/zhaopin/?isAnalysis=&dqs=&pubTime=&salary=&compIds=&subIndustry=&industryType=industry_03&compscale=&key=%E6%95%B0%E6%8D%AE%E5%88%86%E6%9E%90%E5%B8%88&init=-1&searchType=1&headckid=aa4a3ef545437f22&flushckid=1&compkind=&fromSearchBtn=2&sortFlag=15&ckid=bce53da97cf10328&jobKind=&industries=100&clean_condition=&siTag=bFGQTbwE_AAQSb-u11jrBw%7EfA9rXquZc5IkJpXC-Ycixw&d_sfrom=search_prime&d_ckId=591ebc1760fee953b72353bace17e6cc&d_curPage=0&d_pageSize=40&d_headId=591ebc1760fee953b72353bace17e6cc',\n",
       " '房地产服务': '/zhaopin/?isAnalysis=&dqs=&pubTime=&salary=&compIds=&subIndustry=&industryType=industry_03&compscale=&key=%E6%95%B0%E6%8D%AE%E5%88%86%E6%9E%90%E5%B8%88&init=-1&searchType=1&headckid=aa4a3ef545437f22&flushckid=1&compkind=&fromSearchBtn=2&sortFlag=15&ckid=bce53da97cf10328&jobKind=&industries=090&clean_condition=&siTag=bFGQTbwE_AAQSb-u11jrBw%7EfA9rXquZc5IkJpXC-Ycixw&d_sfrom=search_prime&d_ckId=591ebc1760fee953b72353bace17e6cc&d_curPage=0&d_pageSize=40&d_headId=591ebc1760fee953b72353bace17e6cc',\n",
       " '银行': '/zhaopin/?isAnalysis=&dqs=&pubTime=&salary=&compIds=&subIndustry=&industryType=industry_04&compscale=&key=%E6%95%B0%E6%8D%AE%E5%88%86%E6%9E%90%E5%B8%88&init=-1&searchType=1&headckid=aa4a3ef545437f22&flushckid=1&compkind=&fromSearchBtn=2&sortFlag=15&ckid=bce53da97cf10328&jobKind=&industries=130&clean_condition=&siTag=bFGQTbwE_AAQSb-u11jrBw%7EfA9rXquZc5IkJpXC-Ycixw&d_sfrom=search_prime&d_ckId=591ebc1760fee953b72353bace17e6cc&d_curPage=0&d_pageSize=40&d_headId=591ebc1760fee953b72353bace17e6cc',\n",
       " '保险': '/zhaopin/?isAnalysis=&dqs=&pubTime=&salary=&compIds=&subIndustry=&industryType=industry_04&compscale=&key=%E6%95%B0%E6%8D%AE%E5%88%86%E6%9E%90%E5%B8%88&init=-1&searchType=1&headckid=aa4a3ef545437f22&flushckid=1&compkind=&fromSearchBtn=2&sortFlag=15&ckid=bce53da97cf10328&jobKind=&industries=140&clean_condition=&siTag=bFGQTbwE_AAQSb-u11jrBw%7EfA9rXquZc5IkJpXC-Ycixw&d_sfrom=search_prime&d_ckId=591ebc1760fee953b72353bace17e6cc&d_curPage=0&d_pageSize=40&d_headId=591ebc1760fee953b72353bace17e6cc',\n",
       " '基金/证券/投资': '/zhaopin/?isAnalysis=&dqs=&pubTime=&salary=&compIds=&subIndustry=&industryType=industry_04&compscale=&key=%E6%95%B0%E6%8D%AE%E5%88%86%E6%9E%90%E5%B8%88&init=-1&searchType=1&headckid=aa4a3ef545437f22&flushckid=1&compkind=&fromSearchBtn=2&sortFlag=15&ckid=bce53da97cf10328&jobKind=&industries=150&clean_condition=&siTag=bFGQTbwE_AAQSb-u11jrBw%7EfA9rXquZc5IkJpXC-Ycixw&d_sfrom=search_prime&d_ckId=591ebc1760fee953b72353bace17e6cc&d_curPage=0&d_pageSize=40&d_headId=591ebc1760fee953b72353bace17e6cc',\n",
       " '会计/审计': '/zhaopin/?isAnalysis=&dqs=&pubTime=&salary=&compIds=&subIndustry=&industryType=industry_04&compscale=&key=%E6%95%B0%E6%8D%AE%E5%88%86%E6%9E%90%E5%B8%88&init=-1&searchType=1&headckid=aa4a3ef545437f22&flushckid=1&compkind=&fromSearchBtn=2&sortFlag=15&ckid=bce53da97cf10328&jobKind=&industries=430&clean_condition=&siTag=bFGQTbwE_AAQSb-u11jrBw%7EfA9rXquZc5IkJpXC-Ycixw&d_sfrom=search_prime&d_ckId=591ebc1760fee953b72353bace17e6cc&d_curPage=0&d_pageSize=40&d_headId=591ebc1760fee953b72353bace17e6cc',\n",
       " '信托/担保/拍卖': '/zhaopin/?isAnalysis=&dqs=&pubTime=&salary=&compIds=&subIndustry=&industryType=industry_04&compscale=&key=%E6%95%B0%E6%8D%AE%E5%88%86%E6%9E%90%E5%B8%88&init=-1&searchType=1&headckid=aa4a3ef545437f22&flushckid=1&compkind=&fromSearchBtn=2&sortFlag=15&ckid=bce53da97cf10328&jobKind=&industries=500&clean_condition=&siTag=bFGQTbwE_AAQSb-u11jrBw%7EfA9rXquZc5IkJpXC-Ycixw&d_sfrom=search_prime&d_ckId=591ebc1760fee953b72353bace17e6cc&d_curPage=0&d_pageSize=40&d_headId=591ebc1760fee953b72353bace17e6cc',\n",
       " '快消品': '/zhaopin/?isAnalysis=&dqs=&pubTime=&salary=&compIds=&subIndustry=&industryType=industry_05&compscale=&key=%E6%95%B0%E6%8D%AE%E5%88%86%E6%9E%90%E5%B8%88&init=-1&searchType=1&headckid=aa4a3ef545437f22&flushckid=1&compkind=&fromSearchBtn=2&sortFlag=15&ckid=bce53da97cf10328&jobKind=&industries=190&clean_condition=&siTag=bFGQTbwE_AAQSb-u11jrBw%7EfA9rXquZc5IkJpXC-Ycixw&d_sfrom=search_prime&d_ckId=591ebc1760fee953b72353bace17e6cc&d_curPage=0&d_pageSize=40&d_headId=591ebc1760fee953b72353bace17e6cc',\n",
       " '批发零售': '/zhaopin/?isAnalysis=&dqs=&pubTime=&salary=&compIds=&subIndustry=&industryType=industry_05&compscale=&key=%E6%95%B0%E6%8D%AE%E5%88%86%E6%9E%90%E5%B8%88&init=-1&searchType=1&headckid=aa4a3ef545437f22&flushckid=1&compkind=&fromSearchBtn=2&sortFlag=15&ckid=bce53da97cf10328&jobKind=&industries=240&clean_condition=&siTag=bFGQTbwE_AAQSb-u11jrBw%7EfA9rXquZc5IkJpXC-Ycixw&d_sfrom=search_prime&d_ckId=591ebc1760fee953b72353bace17e6cc&d_curPage=0&d_pageSize=40&d_headId=591ebc1760fee953b72353bace17e6cc',\n",
       " '服装纺织': '/zhaopin/?isAnalysis=&dqs=&pubTime=&salary=&compIds=&subIndustry=&industryType=industry_05&compscale=&key=%E6%95%B0%E6%8D%AE%E5%88%86%E6%9E%90%E5%B8%88&init=-1&searchType=1&headckid=aa4a3ef545437f22&flushckid=1&compkind=&fromSearchBtn=2&sortFlag=15&ckid=bce53da97cf10328&jobKind=&industries=200&clean_condition=&siTag=bFGQTbwE_AAQSb-u11jrBw%7EfA9rXquZc5IkJpXC-Ycixw&d_sfrom=search_prime&d_ckId=591ebc1760fee953b72353bace17e6cc&d_curPage=0&d_pageSize=40&d_headId=591ebc1760fee953b72353bace17e6cc',\n",
       " '家具/家电': '/zhaopin/?isAnalysis=&dqs=&pubTime=&salary=&compIds=&subIndustry=&industryType=industry_05&compscale=&key=%E6%95%B0%E6%8D%AE%E5%88%86%E6%9E%90%E5%B8%88&init=-1&searchType=1&headckid=aa4a3ef545437f22&flushckid=1&compkind=&fromSearchBtn=2&sortFlag=15&ckid=bce53da97cf10328&jobKind=&industries=210&clean_condition=&siTag=bFGQTbwE_AAQSb-u11jrBw%7EfA9rXquZc5IkJpXC-Ycixw&d_sfrom=search_prime&d_ckId=591ebc1760fee953b72353bace17e6cc&d_curPage=0&d_pageSize=40&d_headId=591ebc1760fee953b72353bace17e6cc',\n",
       " '办公设备': '/zhaopin/?isAnalysis=&dqs=&pubTime=&salary=&compIds=&subIndustry=&industryType=industry_05&compscale=&key=%E6%95%B0%E6%8D%AE%E5%88%86%E6%9E%90%E5%B8%88&init=-1&searchType=1&headckid=aa4a3ef545437f22&flushckid=1&compkind=&fromSearchBtn=2&sortFlag=15&ckid=bce53da97cf10328&jobKind=&industries=220&clean_condition=&siTag=bFGQTbwE_AAQSb-u11jrBw%7EfA9rXquZc5IkJpXC-Ycixw&d_sfrom=search_prime&d_ckId=591ebc1760fee953b72353bace17e6cc&d_curPage=0&d_pageSize=40&d_headId=591ebc1760fee953b72353bace17e6cc',\n",
       " '奢侈品/收藏品': '/zhaopin/?isAnalysis=&dqs=&pubTime=&salary=&compIds=&subIndustry=&industryType=industry_05&compscale=&key=%E6%95%B0%E6%8D%AE%E5%88%86%E6%9E%90%E5%B8%88&init=-1&searchType=1&headckid=aa4a3ef545437f22&flushckid=1&compkind=&fromSearchBtn=2&sortFlag=15&ckid=bce53da97cf10328&jobKind=&industries=460&clean_condition=&siTag=bFGQTbwE_AAQSb-u11jrBw%7EfA9rXquZc5IkJpXC-Ycixw&d_sfrom=search_prime&d_ckId=591ebc1760fee953b72353bace17e6cc&d_curPage=0&d_pageSize=40&d_headId=591ebc1760fee953b72353bace17e6cc',\n",
       " '珠宝/玩具/工艺品': '/zhaopin/?isAnalysis=&dqs=&pubTime=&salary=&compIds=&subIndustry=&industryType=industry_05&compscale=&key=%E6%95%B0%E6%8D%AE%E5%88%86%E6%9E%90%E5%B8%88&init=-1&searchType=1&headckid=aa4a3ef545437f22&flushckid=1&compkind=&fromSearchBtn=2&sortFlag=15&ckid=bce53da97cf10328&jobKind=&industries=470&clean_condition=&siTag=bFGQTbwE_AAQSb-u11jrBw%7EfA9rXquZc5IkJpXC-Ycixw&d_sfrom=search_prime&d_ckId=591ebc1760fee953b72353bace17e6cc&d_curPage=0&d_pageSize=40&d_headId=591ebc1760fee953b72353bace17e6cc',\n",
       " '汽车/摩托车': '/zhaopin/?isAnalysis=&dqs=&pubTime=&salary=&compIds=&subIndustry=&industryType=industry_06&compscale=&key=%E6%95%B0%E6%8D%AE%E5%88%86%E6%9E%90%E5%B8%88&init=-1&searchType=1&headckid=aa4a3ef545437f22&flushckid=1&compkind=&fromSearchBtn=2&sortFlag=15&ckid=bce53da97cf10328&jobKind=&industries=350&clean_condition=&siTag=bFGQTbwE_AAQSb-u11jrBw%7EfA9rXquZc5IkJpXC-Ycixw&d_sfrom=search_prime&d_ckId=591ebc1760fee953b72353bace17e6cc&d_curPage=0&d_pageSize=40&d_headId=591ebc1760fee953b72353bace17e6cc',\n",
       " '机械/机电/重工': '/zhaopin/?isAnalysis=&dqs=&pubTime=&salary=&compIds=&subIndustry=&industryType=industry_06&compscale=&key=%E6%95%B0%E6%8D%AE%E5%88%86%E6%9E%90%E5%B8%88&init=-1&searchType=1&headckid=aa4a3ef545437f22&flushckid=1&compkind=&fromSearchBtn=2&sortFlag=15&ckid=bce53da97cf10328&jobKind=&industries=360&clean_condition=&siTag=bFGQTbwE_AAQSb-u11jrBw%7EfA9rXquZc5IkJpXC-Ycixw&d_sfrom=search_prime&d_ckId=591ebc1760fee953b72353bace17e6cc&d_curPage=0&d_pageSize=40&d_headId=591ebc1760fee953b72353bace17e6cc',\n",
       " '印刷/包装/造纸': '/zhaopin/?isAnalysis=&dqs=&pubTime=&salary=&compIds=&subIndustry=&industryType=industry_06&compscale=&key=%E6%95%B0%E6%8D%AE%E5%88%86%E6%9E%90%E5%B8%88&init=-1&searchType=1&headckid=aa4a3ef545437f22&flushckid=1&compkind=&fromSearchBtn=2&sortFlag=15&ckid=bce53da97cf10328&jobKind=&industries=180&clean_condition=&siTag=bFGQTbwE_AAQSb-u11jrBw%7EfA9rXquZc5IkJpXC-Ycixw&d_sfrom=search_prime&d_ckId=591ebc1760fee953b72353bace17e6cc&d_curPage=0&d_pageSize=40&d_headId=591ebc1760fee953b72353bace17e6cc',\n",
       " '原材料加工': '/zhaopin/?isAnalysis=&dqs=&pubTime=&salary=&compIds=&subIndustry=&industryType=industry_06&compscale=&key=%E6%95%B0%E6%8D%AE%E5%88%86%E6%9E%90%E5%B8%88&init=-1&searchType=1&headckid=aa4a3ef545437f22&flushckid=1&compkind=&fromSearchBtn=2&sortFlag=15&ckid=bce53da97cf10328&jobKind=&industries=370&clean_condition=&siTag=bFGQTbwE_AAQSb-u11jrBw%7EfA9rXquZc5IkJpXC-Ycixw&d_sfrom=search_prime&d_ckId=591ebc1760fee953b72353bace17e6cc&d_curPage=0&d_pageSize=40&d_headId=591ebc1760fee953b72353bace17e6cc',\n",
       " '仪器/电气/自动化': '/zhaopin/?isAnalysis=&dqs=&pubTime=&salary=&compIds=&subIndustry=&industryType=industry_06&compscale=&key=%E6%95%B0%E6%8D%AE%E5%88%86%E6%9E%90%E5%B8%88&init=-1&searchType=1&headckid=aa4a3ef545437f22&flushckid=1&compkind=&fromSearchBtn=2&sortFlag=15&ckid=bce53da97cf10328&jobKind=&industries=340&clean_condition=&siTag=bFGQTbwE_AAQSb-u11jrBw%7EfA9rXquZc5IkJpXC-Ycixw&d_sfrom=search_prime&d_ckId=591ebc1760fee953b72353bace17e6cc&d_curPage=0&d_pageSize=40&d_headId=591ebc1760fee953b72353bace17e6cc',\n",
       " '制药/生物工程': '/zhaopin/?isAnalysis=&dqs=&pubTime=&salary=&compIds=&subIndustry=&industryType=industry_10&compscale=&key=%E6%95%B0%E6%8D%AE%E5%88%86%E6%9E%90%E5%B8%88&init=-1&searchType=1&headckid=aa4a3ef545437f22&flushckid=1&compkind=&fromSearchBtn=2&sortFlag=15&ckid=bce53da97cf10328&jobKind=&industries=270&clean_condition=&siTag=bFGQTbwE_AAQSb-u11jrBw%7EfA9rXquZc5IkJpXC-Ycixw&d_sfrom=search_prime&d_ckId=591ebc1760fee953b72353bace17e6cc&d_curPage=0&d_pageSize=40&d_headId=591ebc1760fee953b72353bace17e6cc',\n",
       " '医疗/保健/美容': '/zhaopin/?isAnalysis=&dqs=&pubTime=&salary=&compIds=&subIndustry=&industryType=industry_10&compscale=&key=%E6%95%B0%E6%8D%AE%E5%88%86%E6%9E%90%E5%B8%88&init=-1&searchType=1&headckid=aa4a3ef545437f22&flushckid=1&compkind=&fromSearchBtn=2&sortFlag=15&ckid=bce53da97cf10328&jobKind=&industries=280&clean_condition=&siTag=bFGQTbwE_AAQSb-u11jrBw%7EfA9rXquZc5IkJpXC-Ycixw&d_sfrom=search_prime&d_ckId=591ebc1760fee953b72353bace17e6cc&d_curPage=0&d_pageSize=40&d_headId=591ebc1760fee953b72353bace17e6cc',\n",
       " '医疗器械': '/zhaopin/?isAnalysis=&dqs=&pubTime=&salary=&compIds=&subIndustry=&industryType=industry_10&compscale=&key=%E6%95%B0%E6%8D%AE%E5%88%86%E6%9E%90%E5%B8%88&init=-1&searchType=1&headckid=aa4a3ef545437f22&flushckid=1&compkind=&fromSearchBtn=2&sortFlag=15&ckid=bce53da97cf10328&jobKind=&industries=290&clean_condition=&siTag=bFGQTbwE_AAQSb-u11jrBw%7EfA9rXquZc5IkJpXC-Ycixw&d_sfrom=search_prime&d_ckId=591ebc1760fee953b72353bace17e6cc&d_curPage=0&d_pageSize=40&d_headId=591ebc1760fee953b72353bace17e6cc',\n",
       " '能源/水利': '/zhaopin/?isAnalysis=&dqs=&pubTime=&salary=&compIds=&subIndustry=&industryType=industry_11&compscale=&key=%E6%95%B0%E6%8D%AE%E5%88%86%E6%9E%90%E5%B8%88&init=-1&searchType=1&headckid=aa4a3ef545437f22&flushckid=1&compkind=&fromSearchBtn=2&sortFlag=15&ckid=bce53da97cf10328&jobKind=&industries=330&clean_condition=&siTag=bFGQTbwE_AAQSb-u11jrBw%7EfA9rXquZc5IkJpXC-Ycixw&d_sfrom=search_prime&d_ckId=591ebc1760fee953b72353bace17e6cc&d_curPage=0&d_pageSize=40&d_headId=591ebc1760fee953b72353bace17e6cc',\n",
       " '石油/化工': '/zhaopin/?isAnalysis=&dqs=&pubTime=&salary=&compIds=&subIndustry=&industryType=industry_11&compscale=&key=%E6%95%B0%E6%8D%AE%E5%88%86%E6%9E%90%E5%B8%88&init=-1&searchType=1&headckid=aa4a3ef545437f22&flushckid=1&compkind=&fromSearchBtn=2&sortFlag=15&ckid=bce53da97cf10328&jobKind=&industries=310&clean_condition=&siTag=bFGQTbwE_AAQSb-u11jrBw%7EfA9rXquZc5IkJpXC-Ycixw&d_sfrom=search_prime&d_ckId=591ebc1760fee953b72353bace17e6cc&d_curPage=0&d_pageSize=40&d_headId=591ebc1760fee953b72353bace17e6cc',\n",
       " '采掘/冶炼/矿产': '/zhaopin/?isAnalysis=&dqs=&pubTime=&salary=&compIds=&subIndustry=&industryType=industry_11&compscale=&key=%E6%95%B0%E6%8D%AE%E5%88%86%E6%9E%90%E5%B8%88&init=-1&searchType=1&headckid=aa4a3ef545437f22&flushckid=1&compkind=&fromSearchBtn=2&sortFlag=15&ckid=bce53da97cf10328&jobKind=&industries=320&clean_condition=&siTag=bFGQTbwE_AAQSb-u11jrBw%7EfA9rXquZc5IkJpXC-Ycixw&d_sfrom=search_prime&d_ckId=591ebc1760fee953b72353bace17e6cc&d_curPage=0&d_pageSize=40&d_headId=591ebc1760fee953b72353bace17e6cc',\n",
       " '环保': '/zhaopin/?isAnalysis=&dqs=&pubTime=&salary=&compIds=&subIndustry=&industryType=industry_11&compscale=&key=%E6%95%B0%E6%8D%AE%E5%88%86%E6%9E%90%E5%B8%88&init=-1&searchType=1&headckid=aa4a3ef545437f22&flushckid=1&compkind=&fromSearchBtn=2&sortFlag=15&ckid=bce53da97cf10328&jobKind=&industries=300&clean_condition=&siTag=bFGQTbwE_AAQSb-u11jrBw%7EfA9rXquZc5IkJpXC-Ycixw&d_sfrom=search_prime&d_ckId=591ebc1760fee953b72353bace17e6cc&d_curPage=0&d_pageSize=40&d_headId=591ebc1760fee953b72353bace17e6cc',\n",
       " '新能源': '/zhaopin/?isAnalysis=&dqs=&pubTime=&salary=&compIds=&subIndustry=&industryType=industry_11&compscale=&key=%E6%95%B0%E6%8D%AE%E5%88%86%E6%9E%90%E5%B8%88&init=-1&searchType=1&headckid=aa4a3ef545437f22&flushckid=1&compkind=&fromSearchBtn=2&sortFlag=15&ckid=bce53da97cf10328&jobKind=&industries=490&clean_condition=&siTag=bFGQTbwE_AAQSb-u11jrBw%7EfA9rXquZc5IkJpXC-Ycixw&d_sfrom=search_prime&d_ckId=591ebc1760fee953b72353bace17e6cc&d_curPage=0&d_pageSize=40&d_headId=591ebc1760fee953b72353bace17e6cc',\n",
       " '专业服务': '/zhaopin/?isAnalysis=&dqs=&pubTime=&salary=&compIds=&subIndustry=&industryType=industry_07&compscale=&key=%E6%95%B0%E6%8D%AE%E5%88%86%E6%9E%90%E5%B8%88&init=-1&searchType=1&headckid=aa4a3ef545437f22&flushckid=1&compkind=&fromSearchBtn=2&sortFlag=15&ckid=bce53da97cf10328&jobKind=&industries=120&clean_condition=&siTag=bFGQTbwE_AAQSb-u11jrBw%7EfA9rXquZc5IkJpXC-Ycixw&d_sfrom=search_prime&d_ckId=591ebc1760fee953b72353bace17e6cc&d_curPage=0&d_pageSize=40&d_headId=591ebc1760fee953b72353bace17e6cc',\n",
       " '中介服务': '/zhaopin/?isAnalysis=&dqs=&pubTime=&salary=&compIds=&subIndustry=&industryType=industry_07&compscale=&key=%E6%95%B0%E6%8D%AE%E5%88%86%E6%9E%90%E5%B8%88&init=-1&searchType=1&headckid=aa4a3ef545437f22&flushckid=1&compkind=&fromSearchBtn=2&sortFlag=15&ckid=bce53da97cf10328&jobKind=&industries=110&clean_condition=&siTag=bFGQTbwE_AAQSb-u11jrBw%7EfA9rXquZc5IkJpXC-Ycixw&d_sfrom=search_prime&d_ckId=591ebc1760fee953b72353bace17e6cc&d_curPage=0&d_pageSize=40&d_headId=591ebc1760fee953b72353bace17e6cc',\n",
       " '外包服务': '/zhaopin/?isAnalysis=&dqs=&pubTime=&salary=&compIds=&subIndustry=&industryType=industry_07&compscale=&key=%E6%95%B0%E6%8D%AE%E5%88%86%E6%9E%90%E5%B8%88&init=-1&searchType=1&headckid=aa4a3ef545437f22&flushckid=1&compkind=&fromSearchBtn=2&sortFlag=15&ckid=bce53da97cf10328&jobKind=&industries=440&clean_condition=&siTag=bFGQTbwE_AAQSb-u11jrBw%7EfA9rXquZc5IkJpXC-Ycixw&d_sfrom=search_prime&d_ckId=591ebc1760fee953b72353bace17e6cc&d_curPage=0&d_pageSize=40&d_headId=591ebc1760fee953b72353bace17e6cc',\n",
       " '检测/认证': '/zhaopin/?isAnalysis=&dqs=&pubTime=&salary=&compIds=&subIndustry=&industryType=industry_07&compscale=&key=%E6%95%B0%E6%8D%AE%E5%88%86%E6%9E%90%E5%B8%88&init=-1&searchType=1&headckid=aa4a3ef545437f22&flushckid=1&compkind=&fromSearchBtn=2&sortFlag=15&ckid=bce53da97cf10328&jobKind=&industries=450&clean_condition=&siTag=bFGQTbwE_AAQSb-u11jrBw%7EfA9rXquZc5IkJpXC-Ycixw&d_sfrom=search_prime&d_ckId=591ebc1760fee953b72353bace17e6cc&d_curPage=0&d_pageSize=40&d_headId=591ebc1760fee953b72353bace17e6cc',\n",
       " '餐饮/酒旅/服务': '/zhaopin/?isAnalysis=&dqs=&pubTime=&salary=&compIds=&subIndustry=&industryType=industry_07&compscale=&key=%E6%95%B0%E6%8D%AE%E5%88%86%E6%9E%90%E5%B8%88&init=-1&searchType=1&headckid=aa4a3ef545437f22&flushckid=1&compkind=&fromSearchBtn=2&sortFlag=15&ckid=bce53da97cf10328&jobKind=&industries=230&clean_condition=&siTag=bFGQTbwE_AAQSb-u11jrBw%7EfA9rXquZc5IkJpXC-Ycixw&d_sfrom=search_prime&d_ckId=591ebc1760fee953b72353bace17e6cc&d_curPage=0&d_pageSize=40&d_headId=591ebc1760fee953b72353bace17e6cc',\n",
       " '文体娱乐': '/zhaopin/?isAnalysis=&dqs=&pubTime=&salary=&compIds=&subIndustry=&industryType=industry_07&compscale=&key=%E6%95%B0%E6%8D%AE%E5%88%86%E6%9E%90%E5%B8%88&init=-1&searchType=1&headckid=aa4a3ef545437f22&flushckid=1&compkind=&fromSearchBtn=2&sortFlag=15&ckid=bce53da97cf10328&jobKind=&industries=260&clean_condition=&siTag=bFGQTbwE_AAQSb-u11jrBw%7EfA9rXquZc5IkJpXC-Ycixw&d_sfrom=search_prime&d_ckId=591ebc1760fee953b72353bace17e6cc&d_curPage=0&d_pageSize=40&d_headId=591ebc1760fee953b72353bace17e6cc',\n",
       " '租赁服务': '/zhaopin/?isAnalysis=&dqs=&pubTime=&salary=&compIds=&subIndustry=&industryType=industry_07&compscale=&key=%E6%95%B0%E6%8D%AE%E5%88%86%E6%9E%90%E5%B8%88&init=-1&searchType=1&headckid=aa4a3ef545437f22&flushckid=1&compkind=&fromSearchBtn=2&sortFlag=15&ckid=bce53da97cf10328&jobKind=&industries=510&clean_condition=&siTag=bFGQTbwE_AAQSb-u11jrBw%7EfA9rXquZc5IkJpXC-Ycixw&d_sfrom=search_prime&d_ckId=591ebc1760fee953b72353bace17e6cc&d_curPage=0&d_pageSize=40&d_headId=591ebc1760fee953b72353bace17e6cc',\n",
       " '广告/市场/会展': '/zhaopin/?isAnalysis=&dqs=&pubTime=&salary=&compIds=&subIndustry=&industryType=industry_08&compscale=&key=%E6%95%B0%E6%8D%AE%E5%88%86%E6%9E%90%E5%B8%88&init=-1&searchType=1&headckid=aa4a3ef545437f22&flushckid=1&compkind=&fromSearchBtn=2&sortFlag=15&ckid=bce53da97cf10328&jobKind=&industries=070&clean_condition=&siTag=bFGQTbwE_AAQSb-u11jrBw%7EfA9rXquZc5IkJpXC-Ycixw&d_sfrom=search_prime&d_ckId=591ebc1760fee953b72353bace17e6cc&d_curPage=0&d_pageSize=40&d_headId=591ebc1760fee953b72353bace17e6cc',\n",
       " '影视文化': '/zhaopin/?isAnalysis=&dqs=&pubTime=&salary=&compIds=&subIndustry=&industryType=industry_08&compscale=&key=%E6%95%B0%E6%8D%AE%E5%88%86%E6%9E%90%E5%B8%88&init=-1&searchType=1&headckid=aa4a3ef545437f22&flushckid=1&compkind=&fromSearchBtn=2&sortFlag=15&ckid=bce53da97cf10328&jobKind=&industries=170&clean_condition=&siTag=bFGQTbwE_AAQSb-u11jrBw%7EfA9rXquZc5IkJpXC-Ycixw&d_sfrom=search_prime&d_ckId=591ebc1760fee953b72353bace17e6cc&d_curPage=0&d_pageSize=40&d_headId=591ebc1760fee953b72353bace17e6cc',\n",
       " '教育培训': '/zhaopin/?isAnalysis=&dqs=&pubTime=&salary=&compIds=&subIndustry=&industryType=industry_08&compscale=&key=%E6%95%B0%E6%8D%AE%E5%88%86%E6%9E%90%E5%B8%88&init=-1&searchType=1&headckid=aa4a3ef545437f22&flushckid=1&compkind=&fromSearchBtn=2&sortFlag=15&ckid=bce53da97cf10328&jobKind=&industries=380&clean_condition=&siTag=bFGQTbwE_AAQSb-u11jrBw%7EfA9rXquZc5IkJpXC-Ycixw&d_sfrom=search_prime&d_ckId=591ebc1760fee953b72353bace17e6cc&d_curPage=0&d_pageSize=40&d_headId=591ebc1760fee953b72353bace17e6cc',\n",
       " '交通/物流/运输': '/zhaopin/?isAnalysis=&dqs=&pubTime=&salary=&compIds=&subIndustry=&industryType=industry_09&compscale=&key=%E6%95%B0%E6%8D%AE%E5%88%86%E6%9E%90%E5%B8%88&init=-1&searchType=1&headckid=aa4a3ef545437f22&flushckid=1&compkind=&fromSearchBtn=2&sortFlag=15&ckid=bce53da97cf10328&jobKind=&industries=250&clean_condition=&siTag=bFGQTbwE_AAQSb-u11jrBw%7EfA9rXquZc5IkJpXC-Ycixw&d_sfrom=search_prime&d_ckId=591ebc1760fee953b72353bace17e6cc&d_curPage=0&d_pageSize=40&d_headId=591ebc1760fee953b72353bace17e6cc',\n",
       " '贸易/进出口': '/zhaopin/?isAnalysis=&dqs=&pubTime=&salary=&compIds=&subIndustry=&industryType=industry_09&compscale=&key=%E6%95%B0%E6%8D%AE%E5%88%86%E6%9E%90%E5%B8%88&init=-1&searchType=1&headckid=aa4a3ef545437f22&flushckid=1&compkind=&fromSearchBtn=2&sortFlag=15&ckid=bce53da97cf10328&jobKind=&industries=160&clean_condition=&siTag=bFGQTbwE_AAQSb-u11jrBw%7EfA9rXquZc5IkJpXC-Ycixw&d_sfrom=search_prime&d_ckId=591ebc1760fee953b72353bace17e6cc&d_curPage=0&d_pageSize=40&d_headId=591ebc1760fee953b72353bace17e6cc',\n",
       " '航空/航天': '/zhaopin/?isAnalysis=&dqs=&pubTime=&salary=&compIds=&subIndustry=&industryType=industry_09&compscale=&key=%E6%95%B0%E6%8D%AE%E5%88%86%E6%9E%90%E5%B8%88&init=-1&searchType=1&headckid=aa4a3ef545437f22&flushckid=1&compkind=&fromSearchBtn=2&sortFlag=15&ckid=bce53da97cf10328&jobKind=&industries=480&clean_condition=&siTag=bFGQTbwE_AAQSb-u11jrBw%7EfA9rXquZc5IkJpXC-Ycixw&d_sfrom=search_prime&d_ckId=591ebc1760fee953b72353bace17e6cc&d_curPage=0&d_pageSize=40&d_headId=591ebc1760fee953b72353bace17e6cc',\n",
       " '政务/公共服务': '/zhaopin/?isAnalysis=&dqs=&pubTime=&salary=&compIds=&subIndustry=&industryType=industry_12&compscale=&key=%E6%95%B0%E6%8D%AE%E5%88%86%E6%9E%90%E5%B8%88&init=-1&searchType=1&headckid=aa4a3ef545437f22&flushckid=1&compkind=&fromSearchBtn=2&sortFlag=15&ckid=bce53da97cf10328&jobKind=&industries=390&clean_condition=&siTag=bFGQTbwE_AAQSb-u11jrBw%7EfA9rXquZc5IkJpXC-Ycixw&d_sfrom=search_prime&d_ckId=591ebc1760fee953b72353bace17e6cc&d_curPage=0&d_pageSize=40&d_headId=591ebc1760fee953b72353bace17e6cc',\n",
       " '农林牧渔': '/zhaopin/?isAnalysis=&dqs=&pubTime=&salary=&compIds=&subIndustry=&industryType=industry_12&compscale=&key=%E6%95%B0%E6%8D%AE%E5%88%86%E6%9E%90%E5%B8%88&init=-1&searchType=1&headckid=aa4a3ef545437f22&flushckid=1&compkind=&fromSearchBtn=2&sortFlag=15&ckid=bce53da97cf10328&jobKind=&industries=410&clean_condition=&siTag=bFGQTbwE_AAQSb-u11jrBw%7EfA9rXquZc5IkJpXC-Ycixw&d_sfrom=search_prime&d_ckId=591ebc1760fee953b72353bace17e6cc&d_curPage=0&d_pageSize=40&d_headId=591ebc1760fee953b72353bace17e6cc',\n",
       " '其他行业': '/zhaopin/?isAnalysis=&dqs=&pubTime=&salary=&compIds=&subIndustry=&industryType=industry_12&compscale=&key=%E6%95%B0%E6%8D%AE%E5%88%86%E6%9E%90%E5%B8%88&init=-1&searchType=1&headckid=aa4a3ef545437f22&flushckid=1&compkind=&fromSearchBtn=2&sortFlag=15&ckid=bce53da97cf10328&jobKind=&industries=400&clean_condition=&siTag=bFGQTbwE_AAQSb-u11jrBw%7EfA9rXquZc5IkJpXC-Ycixw&d_sfrom=search_prime&d_ckId=591ebc1760fee953b72353bace17e6cc&d_curPage=0&d_pageSize=40&d_headId=591ebc1760fee953b72353bace17e6cc'}"
      ]
     },
     "execution_count": 148,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "from requests_html import HTMLSession\n",
    "session =HTMLSession()\n",
    "url=\"https://www.liepin.com/zhaopin/?isAnalysis=&dqs=&pubTime=&salary=&compIds=&subIndustry=&industryType=&compscale=&key=%E6%95%B0%E6%8D%AE%E5%88%86%E6%9E%90%E5%B8%88&init=-1&searchType=1&headckid=aa4a3ef545437f22&flushckid=1&compkind=&fromSearchBtn=2&sortFlag=15&ckid=eade76aeb6fabe2b&jobKind=&industries=&clean_condition=&siTag=bFGQTbwE_AAQSb-u11jrBw%7EfA9rXquZc5IkJpXC-Ycixw&d_sfrom=search_prime&d_ckId=591ebc1760fee953b72353bace17e6cc&d_curPage=0&d_pageSize=40&d_headId=591ebc1760fee953b72353bace17e6cc\"\n",
    "r=session.get(url)\n",
    "行业大类=r.html.xpath(\"//dd[contains(@class,'select-industry')]/ul[@class='clearfix']/li\")\n",
    "# print(行业大类)\n",
    "行业大类url=r.html.xpath(\"//li/div[@class='sub-industry']/a\")\n",
    "行业大类url\n",
    "e={a.xpath(\"a/text()\")[0]:a.xpath(\"a/@href\")[0] for a in 行业大类url}\n",
    "e\n",
    "行业={x.xpath(\"//li/span/text()\")[0]: x.xpath(\"//li/div[@class='sub-industry']/a/text()\")for x in 行业大类}\n",
    "display(行业)\n",
    "# ef=pd.DataFrame(行业)\n",
    "# ef\n",
    "# 行业大类列表=[x.xpath(\"//li/span/text()\")[0] for x in 行业大类]\n",
    "# print(行业大类列表)\n",
    "行业细分=r.html.xpath(\"//div[@class='sub-industry']/a\")\n",
    "# #行业细分\n",
    "行业列表=[a.xpath(\"a/@href\")[0] for a in 行业细分]\n",
    "行业列表\n",
    "行业字典={a.xpath(\"a/text()\")[0]:a.xpath(\"a/@href\")[0] for a in 行业细分}\n",
    "行业字典\n",
    "#ef=行业字典.T#.rename(columns={0:url})\n",
    "\n",
    "#ef\n",
    "# 行业名称=[a.xpath(\"a/text()\")[0]for a in 行业细分]#pd.Series()\n",
    "# 行业名称\n"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 149,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>scheme</th>\n",
       "      <th>netloc</th>\n",
       "      <th>path</th>\n",
       "      <th>params</th>\n",
       "      <th>query</th>\n",
       "      <th>fragment</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td></td>\n",
       "      <td></td>\n",
       "      <td>/zhaopin/</td>\n",
       "      <td></td>\n",
       "      <td>isAnalysis=&amp;dqs=&amp;pubTime=&amp;salary=&amp;compIds=&amp;sub...</td>\n",
       "      <td></td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td></td>\n",
       "      <td></td>\n",
       "      <td>/zhaopin/</td>\n",
       "      <td></td>\n",
       "      <td>isAnalysis=&amp;dqs=&amp;pubTime=&amp;salary=&amp;compIds=&amp;sub...</td>\n",
       "      <td></td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td></td>\n",
       "      <td></td>\n",
       "      <td>/zhaopin/</td>\n",
       "      <td></td>\n",
       "      <td>isAnalysis=&amp;dqs=&amp;pubTime=&amp;salary=&amp;compIds=&amp;sub...</td>\n",
       "      <td></td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>3</th>\n",
       "      <td></td>\n",
       "      <td></td>\n",
       "      <td>/zhaopin/</td>\n",
       "      <td></td>\n",
       "      <td>isAnalysis=&amp;dqs=&amp;pubTime=&amp;salary=&amp;compIds=&amp;sub...</td>\n",
       "      <td></td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>4</th>\n",
       "      <td></td>\n",
       "      <td></td>\n",
       "      <td>/zhaopin/</td>\n",
       "      <td></td>\n",
       "      <td>isAnalysis=&amp;dqs=&amp;pubTime=&amp;salary=&amp;compIds=&amp;sub...</td>\n",
       "      <td></td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>5</th>\n",
       "      <td></td>\n",
       "      <td></td>\n",
       "      <td>/zhaopin/</td>\n",
       "      <td></td>\n",
       "      <td>isAnalysis=&amp;dqs=&amp;pubTime=&amp;salary=&amp;compIds=&amp;sub...</td>\n",
       "      <td></td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>6</th>\n",
       "      <td></td>\n",
       "      <td></td>\n",
       "      <td>/zhaopin/</td>\n",
       "      <td></td>\n",
       "      <td>isAnalysis=&amp;dqs=&amp;pubTime=&amp;salary=&amp;compIds=&amp;sub...</td>\n",
       "      <td></td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>7</th>\n",
       "      <td></td>\n",
       "      <td></td>\n",
       "      <td>/zhaopin/</td>\n",
       "      <td></td>\n",
       "      <td>isAnalysis=&amp;dqs=&amp;pubTime=&amp;salary=&amp;compIds=&amp;sub...</td>\n",
       "      <td></td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>8</th>\n",
       "      <td></td>\n",
       "      <td></td>\n",
       "      <td>/zhaopin/</td>\n",
       "      <td></td>\n",
       "      <td>isAnalysis=&amp;dqs=&amp;pubTime=&amp;salary=&amp;compIds=&amp;sub...</td>\n",
       "      <td></td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>9</th>\n",
       "      <td></td>\n",
       "      <td></td>\n",
       "      <td>/zhaopin/</td>\n",
       "      <td></td>\n",
       "      <td>isAnalysis=&amp;dqs=&amp;pubTime=&amp;salary=&amp;compIds=&amp;sub...</td>\n",
       "      <td></td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>10</th>\n",
       "      <td></td>\n",
       "      <td></td>\n",
       "      <td>/zhaopin/</td>\n",
       "      <td></td>\n",
       "      <td>isAnalysis=&amp;dqs=&amp;pubTime=&amp;salary=&amp;compIds=&amp;sub...</td>\n",
       "      <td></td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>11</th>\n",
       "      <td></td>\n",
       "      <td></td>\n",
       "      <td>/zhaopin/</td>\n",
       "      <td></td>\n",
       "      <td>isAnalysis=&amp;dqs=&amp;pubTime=&amp;salary=&amp;compIds=&amp;sub...</td>\n",
       "      <td></td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>12</th>\n",
       "      <td></td>\n",
       "      <td></td>\n",
       "      <td>/zhaopin/</td>\n",
       "      <td></td>\n",
       "      <td>isAnalysis=&amp;dqs=&amp;pubTime=&amp;salary=&amp;compIds=&amp;sub...</td>\n",
       "      <td></td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>13</th>\n",
       "      <td></td>\n",
       "      <td></td>\n",
       "      <td>/zhaopin/</td>\n",
       "      <td></td>\n",
       "      <td>isAnalysis=&amp;dqs=&amp;pubTime=&amp;salary=&amp;compIds=&amp;sub...</td>\n",
       "      <td></td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>14</th>\n",
       "      <td></td>\n",
       "      <td></td>\n",
       "      <td>/zhaopin/</td>\n",
       "      <td></td>\n",
       "      <td>isAnalysis=&amp;dqs=&amp;pubTime=&amp;salary=&amp;compIds=&amp;sub...</td>\n",
       "      <td></td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>15</th>\n",
       "      <td></td>\n",
       "      <td></td>\n",
       "      <td>/zhaopin/</td>\n",
       "      <td></td>\n",
       "      <td>isAnalysis=&amp;dqs=&amp;pubTime=&amp;salary=&amp;compIds=&amp;sub...</td>\n",
       "      <td></td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>16</th>\n",
       "      <td></td>\n",
       "      <td></td>\n",
       "      <td>/zhaopin/</td>\n",
       "      <td></td>\n",
       "      <td>isAnalysis=&amp;dqs=&amp;pubTime=&amp;salary=&amp;compIds=&amp;sub...</td>\n",
       "      <td></td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>17</th>\n",
       "      <td></td>\n",
       "      <td></td>\n",
       "      <td>/zhaopin/</td>\n",
       "      <td></td>\n",
       "      <td>isAnalysis=&amp;dqs=&amp;pubTime=&amp;salary=&amp;compIds=&amp;sub...</td>\n",
       "      <td></td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>18</th>\n",
       "      <td></td>\n",
       "      <td></td>\n",
       "      <td>/zhaopin/</td>\n",
       "      <td></td>\n",
       "      <td>isAnalysis=&amp;dqs=&amp;pubTime=&amp;salary=&amp;compIds=&amp;sub...</td>\n",
       "      <td></td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>19</th>\n",
       "      <td></td>\n",
       "      <td></td>\n",
       "      <td>/zhaopin/</td>\n",
       "      <td></td>\n",
       "      <td>isAnalysis=&amp;dqs=&amp;pubTime=&amp;salary=&amp;compIds=&amp;sub...</td>\n",
       "      <td></td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>20</th>\n",
       "      <td></td>\n",
       "      <td></td>\n",
       "      <td>/zhaopin/</td>\n",
       "      <td></td>\n",
       "      <td>isAnalysis=&amp;dqs=&amp;pubTime=&amp;salary=&amp;compIds=&amp;sub...</td>\n",
       "      <td></td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>21</th>\n",
       "      <td></td>\n",
       "      <td></td>\n",
       "      <td>/zhaopin/</td>\n",
       "      <td></td>\n",
       "      <td>isAnalysis=&amp;dqs=&amp;pubTime=&amp;salary=&amp;compIds=&amp;sub...</td>\n",
       "      <td></td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>22</th>\n",
       "      <td></td>\n",
       "      <td></td>\n",
       "      <td>/zhaopin/</td>\n",
       "      <td></td>\n",
       "      <td>isAnalysis=&amp;dqs=&amp;pubTime=&amp;salary=&amp;compIds=&amp;sub...</td>\n",
       "      <td></td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>23</th>\n",
       "      <td></td>\n",
       "      <td></td>\n",
       "      <td>/zhaopin/</td>\n",
       "      <td></td>\n",
       "      <td>isAnalysis=&amp;dqs=&amp;pubTime=&amp;salary=&amp;compIds=&amp;sub...</td>\n",
       "      <td></td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>24</th>\n",
       "      <td></td>\n",
       "      <td></td>\n",
       "      <td>/zhaopin/</td>\n",
       "      <td></td>\n",
       "      <td>isAnalysis=&amp;dqs=&amp;pubTime=&amp;salary=&amp;compIds=&amp;sub...</td>\n",
       "      <td></td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>25</th>\n",
       "      <td></td>\n",
       "      <td></td>\n",
       "      <td>/zhaopin/</td>\n",
       "      <td></td>\n",
       "      <td>isAnalysis=&amp;dqs=&amp;pubTime=&amp;salary=&amp;compIds=&amp;sub...</td>\n",
       "      <td></td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>26</th>\n",
       "      <td></td>\n",
       "      <td></td>\n",
       "      <td>/zhaopin/</td>\n",
       "      <td></td>\n",
       "      <td>isAnalysis=&amp;dqs=&amp;pubTime=&amp;salary=&amp;compIds=&amp;sub...</td>\n",
       "      <td></td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>27</th>\n",
       "      <td></td>\n",
       "      <td></td>\n",
       "      <td>/zhaopin/</td>\n",
       "      <td></td>\n",
       "      <td>isAnalysis=&amp;dqs=&amp;pubTime=&amp;salary=&amp;compIds=&amp;sub...</td>\n",
       "      <td></td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>28</th>\n",
       "      <td></td>\n",
       "      <td></td>\n",
       "      <td>/zhaopin/</td>\n",
       "      <td></td>\n",
       "      <td>isAnalysis=&amp;dqs=&amp;pubTime=&amp;salary=&amp;compIds=&amp;sub...</td>\n",
       "      <td></td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>29</th>\n",
       "      <td></td>\n",
       "      <td></td>\n",
       "      <td>/zhaopin/</td>\n",
       "      <td></td>\n",
       "      <td>isAnalysis=&amp;dqs=&amp;pubTime=&amp;salary=&amp;compIds=&amp;sub...</td>\n",
       "      <td></td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>30</th>\n",
       "      <td></td>\n",
       "      <td></td>\n",
       "      <td>/zhaopin/</td>\n",
       "      <td></td>\n",
       "      <td>isAnalysis=&amp;dqs=&amp;pubTime=&amp;salary=&amp;compIds=&amp;sub...</td>\n",
       "      <td></td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>31</th>\n",
       "      <td></td>\n",
       "      <td></td>\n",
       "      <td>/zhaopin/</td>\n",
       "      <td></td>\n",
       "      <td>isAnalysis=&amp;dqs=&amp;pubTime=&amp;salary=&amp;compIds=&amp;sub...</td>\n",
       "      <td></td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>32</th>\n",
       "      <td></td>\n",
       "      <td></td>\n",
       "      <td>/zhaopin/</td>\n",
       "      <td></td>\n",
       "      <td>isAnalysis=&amp;dqs=&amp;pubTime=&amp;salary=&amp;compIds=&amp;sub...</td>\n",
       "      <td></td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>33</th>\n",
       "      <td></td>\n",
       "      <td></td>\n",
       "      <td>/zhaopin/</td>\n",
       "      <td></td>\n",
       "      <td>isAnalysis=&amp;dqs=&amp;pubTime=&amp;salary=&amp;compIds=&amp;sub...</td>\n",
       "      <td></td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>34</th>\n",
       "      <td></td>\n",
       "      <td></td>\n",
       "      <td>/zhaopin/</td>\n",
       "      <td></td>\n",
       "      <td>isAnalysis=&amp;dqs=&amp;pubTime=&amp;salary=&amp;compIds=&amp;sub...</td>\n",
       "      <td></td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>35</th>\n",
       "      <td></td>\n",
       "      <td></td>\n",
       "      <td>/zhaopin/</td>\n",
       "      <td></td>\n",
       "      <td>isAnalysis=&amp;dqs=&amp;pubTime=&amp;salary=&amp;compIds=&amp;sub...</td>\n",
       "      <td></td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>36</th>\n",
       "      <td></td>\n",
       "      <td></td>\n",
       "      <td>/zhaopin/</td>\n",
       "      <td></td>\n",
       "      <td>isAnalysis=&amp;dqs=&amp;pubTime=&amp;salary=&amp;compIds=&amp;sub...</td>\n",
       "      <td></td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>37</th>\n",
       "      <td></td>\n",
       "      <td></td>\n",
       "      <td>/zhaopin/</td>\n",
       "      <td></td>\n",
       "      <td>isAnalysis=&amp;dqs=&amp;pubTime=&amp;salary=&amp;compIds=&amp;sub...</td>\n",
       "      <td></td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>38</th>\n",
       "      <td></td>\n",
       "      <td></td>\n",
       "      <td>/zhaopin/</td>\n",
       "      <td></td>\n",
       "      <td>isAnalysis=&amp;dqs=&amp;pubTime=&amp;salary=&amp;compIds=&amp;sub...</td>\n",
       "      <td></td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>39</th>\n",
       "      <td></td>\n",
       "      <td></td>\n",
       "      <td>/zhaopin/</td>\n",
       "      <td></td>\n",
       "      <td>isAnalysis=&amp;dqs=&amp;pubTime=&amp;salary=&amp;compIds=&amp;sub...</td>\n",
       "      <td></td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>40</th>\n",
       "      <td></td>\n",
       "      <td></td>\n",
       "      <td>/zhaopin/</td>\n",
       "      <td></td>\n",
       "      <td>isAnalysis=&amp;dqs=&amp;pubTime=&amp;salary=&amp;compIds=&amp;sub...</td>\n",
       "      <td></td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>41</th>\n",
       "      <td></td>\n",
       "      <td></td>\n",
       "      <td>/zhaopin/</td>\n",
       "      <td></td>\n",
       "      <td>isAnalysis=&amp;dqs=&amp;pubTime=&amp;salary=&amp;compIds=&amp;sub...</td>\n",
       "      <td></td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>42</th>\n",
       "      <td></td>\n",
       "      <td></td>\n",
       "      <td>/zhaopin/</td>\n",
       "      <td></td>\n",
       "      <td>isAnalysis=&amp;dqs=&amp;pubTime=&amp;salary=&amp;compIds=&amp;sub...</td>\n",
       "      <td></td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>43</th>\n",
       "      <td></td>\n",
       "      <td></td>\n",
       "      <td>/zhaopin/</td>\n",
       "      <td></td>\n",
       "      <td>isAnalysis=&amp;dqs=&amp;pubTime=&amp;salary=&amp;compIds=&amp;sub...</td>\n",
       "      <td></td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>44</th>\n",
       "      <td></td>\n",
       "      <td></td>\n",
       "      <td>/zhaopin/</td>\n",
       "      <td></td>\n",
       "      <td>isAnalysis=&amp;dqs=&amp;pubTime=&amp;salary=&amp;compIds=&amp;sub...</td>\n",
       "      <td></td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>45</th>\n",
       "      <td></td>\n",
       "      <td></td>\n",
       "      <td>/zhaopin/</td>\n",
       "      <td></td>\n",
       "      <td>isAnalysis=&amp;dqs=&amp;pubTime=&amp;salary=&amp;compIds=&amp;sub...</td>\n",
       "      <td></td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>46</th>\n",
       "      <td></td>\n",
       "      <td></td>\n",
       "      <td>/zhaopin/</td>\n",
       "      <td></td>\n",
       "      <td>isAnalysis=&amp;dqs=&amp;pubTime=&amp;salary=&amp;compIds=&amp;sub...</td>\n",
       "      <td></td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>47</th>\n",
       "      <td></td>\n",
       "      <td></td>\n",
       "      <td>/zhaopin/</td>\n",
       "      <td></td>\n",
       "      <td>isAnalysis=&amp;dqs=&amp;pubTime=&amp;salary=&amp;compIds=&amp;sub...</td>\n",
       "      <td></td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>48</th>\n",
       "      <td></td>\n",
       "      <td></td>\n",
       "      <td>/zhaopin/</td>\n",
       "      <td></td>\n",
       "      <td>isAnalysis=&amp;dqs=&amp;pubTime=&amp;salary=&amp;compIds=&amp;sub...</td>\n",
       "      <td></td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>49</th>\n",
       "      <td></td>\n",
       "      <td></td>\n",
       "      <td>/zhaopin/</td>\n",
       "      <td></td>\n",
       "      <td>isAnalysis=&amp;dqs=&amp;pubTime=&amp;salary=&amp;compIds=&amp;sub...</td>\n",
       "      <td></td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>50</th>\n",
       "      <td></td>\n",
       "      <td></td>\n",
       "      <td>/zhaopin/</td>\n",
       "      <td></td>\n",
       "      <td>isAnalysis=&amp;dqs=&amp;pubTime=&amp;salary=&amp;compIds=&amp;sub...</td>\n",
       "      <td></td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "   scheme netloc       path params  \\\n",
       "0                 /zhaopin/          \n",
       "1                 /zhaopin/          \n",
       "2                 /zhaopin/          \n",
       "3                 /zhaopin/          \n",
       "4                 /zhaopin/          \n",
       "5                 /zhaopin/          \n",
       "6                 /zhaopin/          \n",
       "7                 /zhaopin/          \n",
       "8                 /zhaopin/          \n",
       "9                 /zhaopin/          \n",
       "10                /zhaopin/          \n",
       "11                /zhaopin/          \n",
       "12                /zhaopin/          \n",
       "13                /zhaopin/          \n",
       "14                /zhaopin/          \n",
       "15                /zhaopin/          \n",
       "16                /zhaopin/          \n",
       "17                /zhaopin/          \n",
       "18                /zhaopin/          \n",
       "19                /zhaopin/          \n",
       "20                /zhaopin/          \n",
       "21                /zhaopin/          \n",
       "22                /zhaopin/          \n",
       "23                /zhaopin/          \n",
       "24                /zhaopin/          \n",
       "25                /zhaopin/          \n",
       "26                /zhaopin/          \n",
       "27                /zhaopin/          \n",
       "28                /zhaopin/          \n",
       "29                /zhaopin/          \n",
       "30                /zhaopin/          \n",
       "31                /zhaopin/          \n",
       "32                /zhaopin/          \n",
       "33                /zhaopin/          \n",
       "34                /zhaopin/          \n",
       "35                /zhaopin/          \n",
       "36                /zhaopin/          \n",
       "37                /zhaopin/          \n",
       "38                /zhaopin/          \n",
       "39                /zhaopin/          \n",
       "40                /zhaopin/          \n",
       "41                /zhaopin/          \n",
       "42                /zhaopin/          \n",
       "43                /zhaopin/          \n",
       "44                /zhaopin/          \n",
       "45                /zhaopin/          \n",
       "46                /zhaopin/          \n",
       "47                /zhaopin/          \n",
       "48                /zhaopin/          \n",
       "49                /zhaopin/          \n",
       "50                /zhaopin/          \n",
       "\n",
       "                                                query fragment  \n",
       "0   isAnalysis=&dqs=&pubTime=&salary=&compIds=&sub...           \n",
       "1   isAnalysis=&dqs=&pubTime=&salary=&compIds=&sub...           \n",
       "2   isAnalysis=&dqs=&pubTime=&salary=&compIds=&sub...           \n",
       "3   isAnalysis=&dqs=&pubTime=&salary=&compIds=&sub...           \n",
       "4   isAnalysis=&dqs=&pubTime=&salary=&compIds=&sub...           \n",
       "5   isAnalysis=&dqs=&pubTime=&salary=&compIds=&sub...           \n",
       "6   isAnalysis=&dqs=&pubTime=&salary=&compIds=&sub...           \n",
       "7   isAnalysis=&dqs=&pubTime=&salary=&compIds=&sub...           \n",
       "8   isAnalysis=&dqs=&pubTime=&salary=&compIds=&sub...           \n",
       "9   isAnalysis=&dqs=&pubTime=&salary=&compIds=&sub...           \n",
       "10  isAnalysis=&dqs=&pubTime=&salary=&compIds=&sub...           \n",
       "11  isAnalysis=&dqs=&pubTime=&salary=&compIds=&sub...           \n",
       "12  isAnalysis=&dqs=&pubTime=&salary=&compIds=&sub...           \n",
       "13  isAnalysis=&dqs=&pubTime=&salary=&compIds=&sub...           \n",
       "14  isAnalysis=&dqs=&pubTime=&salary=&compIds=&sub...           \n",
       "15  isAnalysis=&dqs=&pubTime=&salary=&compIds=&sub...           \n",
       "16  isAnalysis=&dqs=&pubTime=&salary=&compIds=&sub...           \n",
       "17  isAnalysis=&dqs=&pubTime=&salary=&compIds=&sub...           \n",
       "18  isAnalysis=&dqs=&pubTime=&salary=&compIds=&sub...           \n",
       "19  isAnalysis=&dqs=&pubTime=&salary=&compIds=&sub...           \n",
       "20  isAnalysis=&dqs=&pubTime=&salary=&compIds=&sub...           \n",
       "21  isAnalysis=&dqs=&pubTime=&salary=&compIds=&sub...           \n",
       "22  isAnalysis=&dqs=&pubTime=&salary=&compIds=&sub...           \n",
       "23  isAnalysis=&dqs=&pubTime=&salary=&compIds=&sub...           \n",
       "24  isAnalysis=&dqs=&pubTime=&salary=&compIds=&sub...           \n",
       "25  isAnalysis=&dqs=&pubTime=&salary=&compIds=&sub...           \n",
       "26  isAnalysis=&dqs=&pubTime=&salary=&compIds=&sub...           \n",
       "27  isAnalysis=&dqs=&pubTime=&salary=&compIds=&sub...           \n",
       "28  isAnalysis=&dqs=&pubTime=&salary=&compIds=&sub...           \n",
       "29  isAnalysis=&dqs=&pubTime=&salary=&compIds=&sub...           \n",
       "30  isAnalysis=&dqs=&pubTime=&salary=&compIds=&sub...           \n",
       "31  isAnalysis=&dqs=&pubTime=&salary=&compIds=&sub...           \n",
       "32  isAnalysis=&dqs=&pubTime=&salary=&compIds=&sub...           \n",
       "33  isAnalysis=&dqs=&pubTime=&salary=&compIds=&sub...           \n",
       "34  isAnalysis=&dqs=&pubTime=&salary=&compIds=&sub...           \n",
       "35  isAnalysis=&dqs=&pubTime=&salary=&compIds=&sub...           \n",
       "36  isAnalysis=&dqs=&pubTime=&salary=&compIds=&sub...           \n",
       "37  isAnalysis=&dqs=&pubTime=&salary=&compIds=&sub...           \n",
       "38  isAnalysis=&dqs=&pubTime=&salary=&compIds=&sub...           \n",
       "39  isAnalysis=&dqs=&pubTime=&salary=&compIds=&sub...           \n",
       "40  isAnalysis=&dqs=&pubTime=&salary=&compIds=&sub...           \n",
       "41  isAnalysis=&dqs=&pubTime=&salary=&compIds=&sub...           \n",
       "42  isAnalysis=&dqs=&pubTime=&salary=&compIds=&sub...           \n",
       "43  isAnalysis=&dqs=&pubTime=&salary=&compIds=&sub...           \n",
       "44  isAnalysis=&dqs=&pubTime=&salary=&compIds=&sub...           \n",
       "45  isAnalysis=&dqs=&pubTime=&salary=&compIds=&sub...           \n",
       "46  isAnalysis=&dqs=&pubTime=&salary=&compIds=&sub...           \n",
       "47  isAnalysis=&dqs=&pubTime=&salary=&compIds=&sub...           \n",
       "48  isAnalysis=&dqs=&pubTime=&salary=&compIds=&sub...           \n",
       "49  isAnalysis=&dqs=&pubTime=&salary=&compIds=&sub...           \n",
       "50  isAnalysis=&dqs=&pubTime=&salary=&compIds=&sub...           "
      ]
     },
     "metadata": {},
     "output_type": "display_data"
    },
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>industryType</th>\n",
       "      <th>key</th>\n",
       "      <th>init</th>\n",
       "      <th>searchType</th>\n",
       "      <th>headckid</th>\n",
       "      <th>flushckid</th>\n",
       "      <th>fromSearchBtn</th>\n",
       "      <th>sortFlag</th>\n",
       "      <th>ckid</th>\n",
       "      <th>industries</th>\n",
       "      <th>siTag</th>\n",
       "      <th>d_sfrom</th>\n",
       "      <th>d_ckId</th>\n",
       "      <th>d_curPage</th>\n",
       "      <th>d_pageSize</th>\n",
       "      <th>d_headId</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>industry_01</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>aa4a3ef545437f22</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>bce53da97cf10328</td>\n",
       "      <td>040</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td>industry_01</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>aa4a3ef545437f22</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>bce53da97cf10328</td>\n",
       "      <td>420</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>industry_01</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>aa4a3ef545437f22</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>bce53da97cf10328</td>\n",
       "      <td>010</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>3</th>\n",
       "      <td>industry_01</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>aa4a3ef545437f22</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>bce53da97cf10328</td>\n",
       "      <td>030</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>4</th>\n",
       "      <td>industry_02</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>aa4a3ef545437f22</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>bce53da97cf10328</td>\n",
       "      <td>050</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>5</th>\n",
       "      <td>industry_02</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>aa4a3ef545437f22</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>bce53da97cf10328</td>\n",
       "      <td>060</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>6</th>\n",
       "      <td>industry_02</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>aa4a3ef545437f22</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>bce53da97cf10328</td>\n",
       "      <td>020</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>7</th>\n",
       "      <td>industry_03</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>aa4a3ef545437f22</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>bce53da97cf10328</td>\n",
       "      <td>080</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>8</th>\n",
       "      <td>industry_03</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>aa4a3ef545437f22</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>bce53da97cf10328</td>\n",
       "      <td>100</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>9</th>\n",
       "      <td>industry_03</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>aa4a3ef545437f22</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>bce53da97cf10328</td>\n",
       "      <td>090</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>10</th>\n",
       "      <td>industry_04</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>aa4a3ef545437f22</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>bce53da97cf10328</td>\n",
       "      <td>130</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>11</th>\n",
       "      <td>industry_04</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>aa4a3ef545437f22</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>bce53da97cf10328</td>\n",
       "      <td>140</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>12</th>\n",
       "      <td>industry_04</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>aa4a3ef545437f22</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>bce53da97cf10328</td>\n",
       "      <td>150</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>13</th>\n",
       "      <td>industry_04</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>aa4a3ef545437f22</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>bce53da97cf10328</td>\n",
       "      <td>430</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>14</th>\n",
       "      <td>industry_04</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>aa4a3ef545437f22</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>bce53da97cf10328</td>\n",
       "      <td>500</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>15</th>\n",
       "      <td>industry_05</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>aa4a3ef545437f22</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>bce53da97cf10328</td>\n",
       "      <td>190</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>16</th>\n",
       "      <td>industry_05</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>aa4a3ef545437f22</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>bce53da97cf10328</td>\n",
       "      <td>240</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>17</th>\n",
       "      <td>industry_05</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>aa4a3ef545437f22</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>bce53da97cf10328</td>\n",
       "      <td>200</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>18</th>\n",
       "      <td>industry_05</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>aa4a3ef545437f22</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>bce53da97cf10328</td>\n",
       "      <td>210</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>19</th>\n",
       "      <td>industry_05</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>aa4a3ef545437f22</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>bce53da97cf10328</td>\n",
       "      <td>220</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>20</th>\n",
       "      <td>industry_05</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>aa4a3ef545437f22</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>bce53da97cf10328</td>\n",
       "      <td>460</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>21</th>\n",
       "      <td>industry_05</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>aa4a3ef545437f22</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>bce53da97cf10328</td>\n",
       "      <td>470</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>22</th>\n",
       "      <td>industry_06</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>aa4a3ef545437f22</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>bce53da97cf10328</td>\n",
       "      <td>350</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>23</th>\n",
       "      <td>industry_06</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>aa4a3ef545437f22</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>bce53da97cf10328</td>\n",
       "      <td>360</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>24</th>\n",
       "      <td>industry_06</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>aa4a3ef545437f22</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>bce53da97cf10328</td>\n",
       "      <td>180</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>25</th>\n",
       "      <td>industry_06</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>aa4a3ef545437f22</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>bce53da97cf10328</td>\n",
       "      <td>370</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>26</th>\n",
       "      <td>industry_06</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>aa4a3ef545437f22</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>bce53da97cf10328</td>\n",
       "      <td>340</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>27</th>\n",
       "      <td>industry_10</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>aa4a3ef545437f22</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>bce53da97cf10328</td>\n",
       "      <td>270</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>28</th>\n",
       "      <td>industry_10</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>aa4a3ef545437f22</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>bce53da97cf10328</td>\n",
       "      <td>280</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>29</th>\n",
       "      <td>industry_10</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>aa4a3ef545437f22</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>bce53da97cf10328</td>\n",
       "      <td>290</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>30</th>\n",
       "      <td>industry_11</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>aa4a3ef545437f22</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>bce53da97cf10328</td>\n",
       "      <td>330</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>31</th>\n",
       "      <td>industry_11</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>aa4a3ef545437f22</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>bce53da97cf10328</td>\n",
       "      <td>310</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>32</th>\n",
       "      <td>industry_11</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>aa4a3ef545437f22</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>bce53da97cf10328</td>\n",
       "      <td>320</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>33</th>\n",
       "      <td>industry_11</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>aa4a3ef545437f22</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>bce53da97cf10328</td>\n",
       "      <td>300</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>34</th>\n",
       "      <td>industry_11</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>aa4a3ef545437f22</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>bce53da97cf10328</td>\n",
       "      <td>490</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>35</th>\n",
       "      <td>industry_07</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>aa4a3ef545437f22</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>bce53da97cf10328</td>\n",
       "      <td>120</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>36</th>\n",
       "      <td>industry_07</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>aa4a3ef545437f22</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>bce53da97cf10328</td>\n",
       "      <td>110</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>37</th>\n",
       "      <td>industry_07</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>aa4a3ef545437f22</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>bce53da97cf10328</td>\n",
       "      <td>440</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>38</th>\n",
       "      <td>industry_07</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>aa4a3ef545437f22</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>bce53da97cf10328</td>\n",
       "      <td>450</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>39</th>\n",
       "      <td>industry_07</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>aa4a3ef545437f22</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>bce53da97cf10328</td>\n",
       "      <td>230</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>40</th>\n",
       "      <td>industry_07</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>aa4a3ef545437f22</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>bce53da97cf10328</td>\n",
       "      <td>260</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>41</th>\n",
       "      <td>industry_07</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>aa4a3ef545437f22</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>bce53da97cf10328</td>\n",
       "      <td>510</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>42</th>\n",
       "      <td>industry_08</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>aa4a3ef545437f22</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>bce53da97cf10328</td>\n",
       "      <td>070</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>43</th>\n",
       "      <td>industry_08</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>aa4a3ef545437f22</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>bce53da97cf10328</td>\n",
       "      <td>170</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>44</th>\n",
       "      <td>industry_08</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>aa4a3ef545437f22</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>bce53da97cf10328</td>\n",
       "      <td>380</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>45</th>\n",
       "      <td>industry_09</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>aa4a3ef545437f22</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>bce53da97cf10328</td>\n",
       "      <td>250</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>46</th>\n",
       "      <td>industry_09</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>aa4a3ef545437f22</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>bce53da97cf10328</td>\n",
       "      <td>160</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>47</th>\n",
       "      <td>industry_09</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>aa4a3ef545437f22</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>bce53da97cf10328</td>\n",
       "      <td>480</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>48</th>\n",
       "      <td>industry_12</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>aa4a3ef545437f22</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>bce53da97cf10328</td>\n",
       "      <td>390</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>49</th>\n",
       "      <td>industry_12</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>aa4a3ef545437f22</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>bce53da97cf10328</td>\n",
       "      <td>410</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>50</th>\n",
       "      <td>industry_12</td>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>aa4a3ef545437f22</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>bce53da97cf10328</td>\n",
       "      <td>400</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "   industryType    key init searchType          headckid flushckid  \\\n",
       "0   industry_01  数据分析师   -1          1  aa4a3ef545437f22         1   \n",
       "1   industry_01  数据分析师   -1          1  aa4a3ef545437f22         1   \n",
       "2   industry_01  数据分析师   -1          1  aa4a3ef545437f22         1   \n",
       "3   industry_01  数据分析师   -1          1  aa4a3ef545437f22         1   \n",
       "4   industry_02  数据分析师   -1          1  aa4a3ef545437f22         1   \n",
       "5   industry_02  数据分析师   -1          1  aa4a3ef545437f22         1   \n",
       "6   industry_02  数据分析师   -1          1  aa4a3ef545437f22         1   \n",
       "7   industry_03  数据分析师   -1          1  aa4a3ef545437f22         1   \n",
       "8   industry_03  数据分析师   -1          1  aa4a3ef545437f22         1   \n",
       "9   industry_03  数据分析师   -1          1  aa4a3ef545437f22         1   \n",
       "10  industry_04  数据分析师   -1          1  aa4a3ef545437f22         1   \n",
       "11  industry_04  数据分析师   -1          1  aa4a3ef545437f22         1   \n",
       "12  industry_04  数据分析师   -1          1  aa4a3ef545437f22         1   \n",
       "13  industry_04  数据分析师   -1          1  aa4a3ef545437f22         1   \n",
       "14  industry_04  数据分析师   -1          1  aa4a3ef545437f22         1   \n",
       "15  industry_05  数据分析师   -1          1  aa4a3ef545437f22         1   \n",
       "16  industry_05  数据分析师   -1          1  aa4a3ef545437f22         1   \n",
       "17  industry_05  数据分析师   -1          1  aa4a3ef545437f22         1   \n",
       "18  industry_05  数据分析师   -1          1  aa4a3ef545437f22         1   \n",
       "19  industry_05  数据分析师   -1          1  aa4a3ef545437f22         1   \n",
       "20  industry_05  数据分析师   -1          1  aa4a3ef545437f22         1   \n",
       "21  industry_05  数据分析师   -1          1  aa4a3ef545437f22         1   \n",
       "22  industry_06  数据分析师   -1          1  aa4a3ef545437f22         1   \n",
       "23  industry_06  数据分析师   -1          1  aa4a3ef545437f22         1   \n",
       "24  industry_06  数据分析师   -1          1  aa4a3ef545437f22         1   \n",
       "25  industry_06  数据分析师   -1          1  aa4a3ef545437f22         1   \n",
       "26  industry_06  数据分析师   -1          1  aa4a3ef545437f22         1   \n",
       "27  industry_10  数据分析师   -1          1  aa4a3ef545437f22         1   \n",
       "28  industry_10  数据分析师   -1          1  aa4a3ef545437f22         1   \n",
       "29  industry_10  数据分析师   -1          1  aa4a3ef545437f22         1   \n",
       "30  industry_11  数据分析师   -1          1  aa4a3ef545437f22         1   \n",
       "31  industry_11  数据分析师   -1          1  aa4a3ef545437f22         1   \n",
       "32  industry_11  数据分析师   -1          1  aa4a3ef545437f22         1   \n",
       "33  industry_11  数据分析师   -1          1  aa4a3ef545437f22         1   \n",
       "34  industry_11  数据分析师   -1          1  aa4a3ef545437f22         1   \n",
       "35  industry_07  数据分析师   -1          1  aa4a3ef545437f22         1   \n",
       "36  industry_07  数据分析师   -1          1  aa4a3ef545437f22         1   \n",
       "37  industry_07  数据分析师   -1          1  aa4a3ef545437f22         1   \n",
       "38  industry_07  数据分析师   -1          1  aa4a3ef545437f22         1   \n",
       "39  industry_07  数据分析师   -1          1  aa4a3ef545437f22         1   \n",
       "40  industry_07  数据分析师   -1          1  aa4a3ef545437f22         1   \n",
       "41  industry_07  数据分析师   -1          1  aa4a3ef545437f22         1   \n",
       "42  industry_08  数据分析师   -1          1  aa4a3ef545437f22         1   \n",
       "43  industry_08  数据分析师   -1          1  aa4a3ef545437f22         1   \n",
       "44  industry_08  数据分析师   -1          1  aa4a3ef545437f22         1   \n",
       "45  industry_09  数据分析师   -1          1  aa4a3ef545437f22         1   \n",
       "46  industry_09  数据分析师   -1          1  aa4a3ef545437f22         1   \n",
       "47  industry_09  数据分析师   -1          1  aa4a3ef545437f22         1   \n",
       "48  industry_12  数据分析师   -1          1  aa4a3ef545437f22         1   \n",
       "49  industry_12  数据分析师   -1          1  aa4a3ef545437f22         1   \n",
       "50  industry_12  数据分析师   -1          1  aa4a3ef545437f22         1   \n",
       "\n",
       "   fromSearchBtn sortFlag              ckid industries  \\\n",
       "0              2       15  bce53da97cf10328        040   \n",
       "1              2       15  bce53da97cf10328        420   \n",
       "2              2       15  bce53da97cf10328        010   \n",
       "3              2       15  bce53da97cf10328        030   \n",
       "4              2       15  bce53da97cf10328        050   \n",
       "5              2       15  bce53da97cf10328        060   \n",
       "6              2       15  bce53da97cf10328        020   \n",
       "7              2       15  bce53da97cf10328        080   \n",
       "8              2       15  bce53da97cf10328        100   \n",
       "9              2       15  bce53da97cf10328        090   \n",
       "10             2       15  bce53da97cf10328        130   \n",
       "11             2       15  bce53da97cf10328        140   \n",
       "12             2       15  bce53da97cf10328        150   \n",
       "13             2       15  bce53da97cf10328        430   \n",
       "14             2       15  bce53da97cf10328        500   \n",
       "15             2       15  bce53da97cf10328        190   \n",
       "16             2       15  bce53da97cf10328        240   \n",
       "17             2       15  bce53da97cf10328        200   \n",
       "18             2       15  bce53da97cf10328        210   \n",
       "19             2       15  bce53da97cf10328        220   \n",
       "20             2       15  bce53da97cf10328        460   \n",
       "21             2       15  bce53da97cf10328        470   \n",
       "22             2       15  bce53da97cf10328        350   \n",
       "23             2       15  bce53da97cf10328        360   \n",
       "24             2       15  bce53da97cf10328        180   \n",
       "25             2       15  bce53da97cf10328        370   \n",
       "26             2       15  bce53da97cf10328        340   \n",
       "27             2       15  bce53da97cf10328        270   \n",
       "28             2       15  bce53da97cf10328        280   \n",
       "29             2       15  bce53da97cf10328        290   \n",
       "30             2       15  bce53da97cf10328        330   \n",
       "31             2       15  bce53da97cf10328        310   \n",
       "32             2       15  bce53da97cf10328        320   \n",
       "33             2       15  bce53da97cf10328        300   \n",
       "34             2       15  bce53da97cf10328        490   \n",
       "35             2       15  bce53da97cf10328        120   \n",
       "36             2       15  bce53da97cf10328        110   \n",
       "37             2       15  bce53da97cf10328        440   \n",
       "38             2       15  bce53da97cf10328        450   \n",
       "39             2       15  bce53da97cf10328        230   \n",
       "40             2       15  bce53da97cf10328        260   \n",
       "41             2       15  bce53da97cf10328        510   \n",
       "42             2       15  bce53da97cf10328        070   \n",
       "43             2       15  bce53da97cf10328        170   \n",
       "44             2       15  bce53da97cf10328        380   \n",
       "45             2       15  bce53da97cf10328        250   \n",
       "46             2       15  bce53da97cf10328        160   \n",
       "47             2       15  bce53da97cf10328        480   \n",
       "48             2       15  bce53da97cf10328        390   \n",
       "49             2       15  bce53da97cf10328        410   \n",
       "50             2       15  bce53da97cf10328        400   \n",
       "\n",
       "                                            siTag       d_sfrom  \\\n",
       "0   bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw  search_prime   \n",
       "1   bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw  search_prime   \n",
       "2   bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw  search_prime   \n",
       "3   bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw  search_prime   \n",
       "4   bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw  search_prime   \n",
       "5   bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw  search_prime   \n",
       "6   bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw  search_prime   \n",
       "7   bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw  search_prime   \n",
       "8   bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw  search_prime   \n",
       "9   bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw  search_prime   \n",
       "10  bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw  search_prime   \n",
       "11  bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw  search_prime   \n",
       "12  bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw  search_prime   \n",
       "13  bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw  search_prime   \n",
       "14  bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw  search_prime   \n",
       "15  bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw  search_prime   \n",
       "16  bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw  search_prime   \n",
       "17  bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw  search_prime   \n",
       "18  bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw  search_prime   \n",
       "19  bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw  search_prime   \n",
       "20  bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw  search_prime   \n",
       "21  bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw  search_prime   \n",
       "22  bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw  search_prime   \n",
       "23  bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw  search_prime   \n",
       "24  bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw  search_prime   \n",
       "25  bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw  search_prime   \n",
       "26  bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw  search_prime   \n",
       "27  bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw  search_prime   \n",
       "28  bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw  search_prime   \n",
       "29  bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw  search_prime   \n",
       "30  bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw  search_prime   \n",
       "31  bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw  search_prime   \n",
       "32  bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw  search_prime   \n",
       "33  bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw  search_prime   \n",
       "34  bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw  search_prime   \n",
       "35  bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw  search_prime   \n",
       "36  bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw  search_prime   \n",
       "37  bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw  search_prime   \n",
       "38  bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw  search_prime   \n",
       "39  bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw  search_prime   \n",
       "40  bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw  search_prime   \n",
       "41  bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw  search_prime   \n",
       "42  bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw  search_prime   \n",
       "43  bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw  search_prime   \n",
       "44  bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw  search_prime   \n",
       "45  bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw  search_prime   \n",
       "46  bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw  search_prime   \n",
       "47  bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw  search_prime   \n",
       "48  bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw  search_prime   \n",
       "49  bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw  search_prime   \n",
       "50  bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw  search_prime   \n",
       "\n",
       "                              d_ckId d_curPage d_pageSize  \\\n",
       "0   591ebc1760fee953b72353bace17e6cc         0         40   \n",
       "1   591ebc1760fee953b72353bace17e6cc         0         40   \n",
       "2   591ebc1760fee953b72353bace17e6cc         0         40   \n",
       "3   591ebc1760fee953b72353bace17e6cc         0         40   \n",
       "4   591ebc1760fee953b72353bace17e6cc         0         40   \n",
       "5   591ebc1760fee953b72353bace17e6cc         0         40   \n",
       "6   591ebc1760fee953b72353bace17e6cc         0         40   \n",
       "7   591ebc1760fee953b72353bace17e6cc         0         40   \n",
       "8   591ebc1760fee953b72353bace17e6cc         0         40   \n",
       "9   591ebc1760fee953b72353bace17e6cc         0         40   \n",
       "10  591ebc1760fee953b72353bace17e6cc         0         40   \n",
       "11  591ebc1760fee953b72353bace17e6cc         0         40   \n",
       "12  591ebc1760fee953b72353bace17e6cc         0         40   \n",
       "13  591ebc1760fee953b72353bace17e6cc         0         40   \n",
       "14  591ebc1760fee953b72353bace17e6cc         0         40   \n",
       "15  591ebc1760fee953b72353bace17e6cc         0         40   \n",
       "16  591ebc1760fee953b72353bace17e6cc         0         40   \n",
       "17  591ebc1760fee953b72353bace17e6cc         0         40   \n",
       "18  591ebc1760fee953b72353bace17e6cc         0         40   \n",
       "19  591ebc1760fee953b72353bace17e6cc         0         40   \n",
       "20  591ebc1760fee953b72353bace17e6cc         0         40   \n",
       "21  591ebc1760fee953b72353bace17e6cc         0         40   \n",
       "22  591ebc1760fee953b72353bace17e6cc         0         40   \n",
       "23  591ebc1760fee953b72353bace17e6cc         0         40   \n",
       "24  591ebc1760fee953b72353bace17e6cc         0         40   \n",
       "25  591ebc1760fee953b72353bace17e6cc         0         40   \n",
       "26  591ebc1760fee953b72353bace17e6cc         0         40   \n",
       "27  591ebc1760fee953b72353bace17e6cc         0         40   \n",
       "28  591ebc1760fee953b72353bace17e6cc         0         40   \n",
       "29  591ebc1760fee953b72353bace17e6cc         0         40   \n",
       "30  591ebc1760fee953b72353bace17e6cc         0         40   \n",
       "31  591ebc1760fee953b72353bace17e6cc         0         40   \n",
       "32  591ebc1760fee953b72353bace17e6cc         0         40   \n",
       "33  591ebc1760fee953b72353bace17e6cc         0         40   \n",
       "34  591ebc1760fee953b72353bace17e6cc         0         40   \n",
       "35  591ebc1760fee953b72353bace17e6cc         0         40   \n",
       "36  591ebc1760fee953b72353bace17e6cc         0         40   \n",
       "37  591ebc1760fee953b72353bace17e6cc         0         40   \n",
       "38  591ebc1760fee953b72353bace17e6cc         0         40   \n",
       "39  591ebc1760fee953b72353bace17e6cc         0         40   \n",
       "40  591ebc1760fee953b72353bace17e6cc         0         40   \n",
       "41  591ebc1760fee953b72353bace17e6cc         0         40   \n",
       "42  591ebc1760fee953b72353bace17e6cc         0         40   \n",
       "43  591ebc1760fee953b72353bace17e6cc         0         40   \n",
       "44  591ebc1760fee953b72353bace17e6cc         0         40   \n",
       "45  591ebc1760fee953b72353bace17e6cc         0         40   \n",
       "46  591ebc1760fee953b72353bace17e6cc         0         40   \n",
       "47  591ebc1760fee953b72353bace17e6cc         0         40   \n",
       "48  591ebc1760fee953b72353bace17e6cc         0         40   \n",
       "49  591ebc1760fee953b72353bace17e6cc         0         40   \n",
       "50  591ebc1760fee953b72353bace17e6cc         0         40   \n",
       "\n",
       "                            d_headId  \n",
       "0   591ebc1760fee953b72353bace17e6cc  \n",
       "1   591ebc1760fee953b72353bace17e6cc  \n",
       "2   591ebc1760fee953b72353bace17e6cc  \n",
       "3   591ebc1760fee953b72353bace17e6cc  \n",
       "4   591ebc1760fee953b72353bace17e6cc  \n",
       "5   591ebc1760fee953b72353bace17e6cc  \n",
       "6   591ebc1760fee953b72353bace17e6cc  \n",
       "7   591ebc1760fee953b72353bace17e6cc  \n",
       "8   591ebc1760fee953b72353bace17e6cc  \n",
       "9   591ebc1760fee953b72353bace17e6cc  \n",
       "10  591ebc1760fee953b72353bace17e6cc  \n",
       "11  591ebc1760fee953b72353bace17e6cc  \n",
       "12  591ebc1760fee953b72353bace17e6cc  \n",
       "13  591ebc1760fee953b72353bace17e6cc  \n",
       "14  591ebc1760fee953b72353bace17e6cc  \n",
       "15  591ebc1760fee953b72353bace17e6cc  \n",
       "16  591ebc1760fee953b72353bace17e6cc  \n",
       "17  591ebc1760fee953b72353bace17e6cc  \n",
       "18  591ebc1760fee953b72353bace17e6cc  \n",
       "19  591ebc1760fee953b72353bace17e6cc  \n",
       "20  591ebc1760fee953b72353bace17e6cc  \n",
       "21  591ebc1760fee953b72353bace17e6cc  \n",
       "22  591ebc1760fee953b72353bace17e6cc  \n",
       "23  591ebc1760fee953b72353bace17e6cc  \n",
       "24  591ebc1760fee953b72353bace17e6cc  \n",
       "25  591ebc1760fee953b72353bace17e6cc  \n",
       "26  591ebc1760fee953b72353bace17e6cc  \n",
       "27  591ebc1760fee953b72353bace17e6cc  \n",
       "28  591ebc1760fee953b72353bace17e6cc  \n",
       "29  591ebc1760fee953b72353bace17e6cc  \n",
       "30  591ebc1760fee953b72353bace17e6cc  \n",
       "31  591ebc1760fee953b72353bace17e6cc  \n",
       "32  591ebc1760fee953b72353bace17e6cc  \n",
       "33  591ebc1760fee953b72353bace17e6cc  \n",
       "34  591ebc1760fee953b72353bace17e6cc  \n",
       "35  591ebc1760fee953b72353bace17e6cc  \n",
       "36  591ebc1760fee953b72353bace17e6cc  \n",
       "37  591ebc1760fee953b72353bace17e6cc  \n",
       "38  591ebc1760fee953b72353bace17e6cc  \n",
       "39  591ebc1760fee953b72353bace17e6cc  \n",
       "40  591ebc1760fee953b72353bace17e6cc  \n",
       "41  591ebc1760fee953b72353bace17e6cc  \n",
       "42  591ebc1760fee953b72353bace17e6cc  \n",
       "43  591ebc1760fee953b72353bace17e6cc  \n",
       "44  591ebc1760fee953b72353bace17e6cc  \n",
       "45  591ebc1760fee953b72353bace17e6cc  \n",
       "46  591ebc1760fee953b72353bace17e6cc  \n",
       "47  591ebc1760fee953b72353bace17e6cc  \n",
       "48  591ebc1760fee953b72353bace17e6cc  \n",
       "49  591ebc1760fee953b72353bace17e6cc  \n",
       "50  591ebc1760fee953b72353bace17e6cc  "
      ]
     },
     "execution_count": 149,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "import pandas as pd\n",
    "from urllib.parse import urlparse, parse_qs\n",
    "# 参数url=[urlparse(a) for a in 行业字典.values()]\n",
    "# 参数url\n",
    "df =pd.DataFrame([urlparse(a) for a in 行业列表])\n",
    "display(df)\n",
    "df_qs = pd.DataFrame([{k:v[0] for k,v in parse_qs(x).items()}   for x in df['query']])\n",
    "df_qs\n",
    "#df_qs.nunique()\n",
    "# df_qs.assign(行业名称=行业名称,axis=1)\n",
    "# df_qs#[['行业名称','industries','industryType']]\n",
    "#df_qs.nunique()\n",
    "# ef=pd.DataFrame(df_qs)\n",
    "# ef\n",
    "#df.nunique()"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 150,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "{'industryType': ['industry_01'],\n",
       " 'key': ['数据分析师'],\n",
       " 'init': ['-1'],\n",
       " 'searchType': ['1'],\n",
       " 'headckid': ['aa4a3ef545437f22'],\n",
       " 'flushckid': ['1'],\n",
       " 'fromSearchBtn': ['2'],\n",
       " 'sortFlag': ['15'],\n",
       " 'ckid': ['bce53da97cf10328'],\n",
       " 'industries': ['040'],\n",
       " 'siTag': ['bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw'],\n",
       " 'd_sfrom': ['search_prime'],\n",
       " 'd_ckId': ['591ebc1760fee953b72353bace17e6cc'],\n",
       " 'd_curPage': ['0'],\n",
       " 'd_pageSize': ['40'],\n",
       " 'd_headId': ['591ebc1760fee953b72353bace17e6cc']}"
      ]
     },
     "execution_count": 150,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "def 行业参数拆解(url):\n",
    "    sixpart=urlparse(url)\n",
    "    out=parse_qs(sixpart.query)\n",
    "    return out\n",
    "行业参数=行业参数拆解(行业列表[0])\n",
    "行业参数\n",
    "\n"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 45,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>行业代号</th>\n",
       "      <th>行业大类代号</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>互联网/电商</th>\n",
       "      <td>040</td>\n",
       "      <td>industry_01</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>游戏产业</th>\n",
       "      <td>420</td>\n",
       "      <td>industry_01</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>计算机软件</th>\n",
       "      <td>010</td>\n",
       "      <td>industry_01</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>IT服务</th>\n",
       "      <td>030</td>\n",
       "      <td>industry_01</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>电子/芯片/半导体</th>\n",
       "      <td>050</td>\n",
       "      <td>industry_02</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>通信业</th>\n",
       "      <td>060</td>\n",
       "      <td>industry_02</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>计算机/网络设备</th>\n",
       "      <td>020</td>\n",
       "      <td>industry_02</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>房地产/建筑</th>\n",
       "      <td>080</td>\n",
       "      <td>industry_03</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>规划/设计/装潢</th>\n",
       "      <td>100</td>\n",
       "      <td>industry_03</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>房地产服务</th>\n",
       "      <td>090</td>\n",
       "      <td>industry_03</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>银行</th>\n",
       "      <td>130</td>\n",
       "      <td>industry_04</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>保险</th>\n",
       "      <td>140</td>\n",
       "      <td>industry_04</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>基金/证券/投资</th>\n",
       "      <td>150</td>\n",
       "      <td>industry_04</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>会计/审计</th>\n",
       "      <td>430</td>\n",
       "      <td>industry_04</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>信托/担保/拍卖</th>\n",
       "      <td>500</td>\n",
       "      <td>industry_04</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>快消品</th>\n",
       "      <td>190</td>\n",
       "      <td>industry_05</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>批发零售</th>\n",
       "      <td>240</td>\n",
       "      <td>industry_05</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>服装纺织</th>\n",
       "      <td>200</td>\n",
       "      <td>industry_05</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>家具/家电</th>\n",
       "      <td>210</td>\n",
       "      <td>industry_05</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>办公设备</th>\n",
       "      <td>220</td>\n",
       "      <td>industry_05</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>奢侈品/收藏品</th>\n",
       "      <td>460</td>\n",
       "      <td>industry_05</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>珠宝/玩具/工艺品</th>\n",
       "      <td>470</td>\n",
       "      <td>industry_05</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>汽车/摩托车</th>\n",
       "      <td>350</td>\n",
       "      <td>industry_06</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>机械/机电/重工</th>\n",
       "      <td>360</td>\n",
       "      <td>industry_06</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>印刷/包装/造纸</th>\n",
       "      <td>180</td>\n",
       "      <td>industry_06</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>原材料加工</th>\n",
       "      <td>370</td>\n",
       "      <td>industry_06</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>仪器/电气/自动化</th>\n",
       "      <td>340</td>\n",
       "      <td>industry_06</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>制药/生物工程</th>\n",
       "      <td>270</td>\n",
       "      <td>industry_10</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>医疗/保健/美容</th>\n",
       "      <td>280</td>\n",
       "      <td>industry_10</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>医疗器械</th>\n",
       "      <td>290</td>\n",
       "      <td>industry_10</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>能源/水利</th>\n",
       "      <td>330</td>\n",
       "      <td>industry_11</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>石油/化工</th>\n",
       "      <td>310</td>\n",
       "      <td>industry_11</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>采掘/冶炼/矿产</th>\n",
       "      <td>320</td>\n",
       "      <td>industry_11</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>环保</th>\n",
       "      <td>300</td>\n",
       "      <td>industry_11</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>新能源</th>\n",
       "      <td>490</td>\n",
       "      <td>industry_11</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>专业服务</th>\n",
       "      <td>120</td>\n",
       "      <td>industry_07</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>中介服务</th>\n",
       "      <td>110</td>\n",
       "      <td>industry_07</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>外包服务</th>\n",
       "      <td>440</td>\n",
       "      <td>industry_07</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>检测/认证</th>\n",
       "      <td>450</td>\n",
       "      <td>industry_07</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>餐饮/酒旅/服务</th>\n",
       "      <td>230</td>\n",
       "      <td>industry_07</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>文体娱乐</th>\n",
       "      <td>260</td>\n",
       "      <td>industry_07</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>租赁服务</th>\n",
       "      <td>510</td>\n",
       "      <td>industry_07</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>广告/市场/会展</th>\n",
       "      <td>070</td>\n",
       "      <td>industry_08</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>影视文化</th>\n",
       "      <td>170</td>\n",
       "      <td>industry_08</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>教育培训</th>\n",
       "      <td>380</td>\n",
       "      <td>industry_08</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>交通/物流/运输</th>\n",
       "      <td>250</td>\n",
       "      <td>industry_09</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>贸易/进出口</th>\n",
       "      <td>160</td>\n",
       "      <td>industry_09</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>航空/航天</th>\n",
       "      <td>480</td>\n",
       "      <td>industry_09</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>政务/公共服务</th>\n",
       "      <td>390</td>\n",
       "      <td>industry_12</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>农林牧渔</th>\n",
       "      <td>410</td>\n",
       "      <td>industry_12</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>其他行业</th>\n",
       "      <td>400</td>\n",
       "      <td>industry_12</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "          行业代号       行业大类代号\n",
       "互联网/电商     040  industry_01\n",
       "游戏产业       420  industry_01\n",
       "计算机软件      010  industry_01\n",
       "IT服务       030  industry_01\n",
       "电子/芯片/半导体  050  industry_02\n",
       "通信业        060  industry_02\n",
       "计算机/网络设备   020  industry_02\n",
       "房地产/建筑     080  industry_03\n",
       "规划/设计/装潢   100  industry_03\n",
       "房地产服务      090  industry_03\n",
       "银行         130  industry_04\n",
       "保险         140  industry_04\n",
       "基金/证券/投资   150  industry_04\n",
       "会计/审计      430  industry_04\n",
       "信托/担保/拍卖   500  industry_04\n",
       "快消品        190  industry_05\n",
       "批发零售       240  industry_05\n",
       "服装纺织       200  industry_05\n",
       "家具/家电      210  industry_05\n",
       "办公设备       220  industry_05\n",
       "奢侈品/收藏品    460  industry_05\n",
       "珠宝/玩具/工艺品  470  industry_05\n",
       "汽车/摩托车     350  industry_06\n",
       "机械/机电/重工   360  industry_06\n",
       "印刷/包装/造纸   180  industry_06\n",
       "原材料加工      370  industry_06\n",
       "仪器/电气/自动化  340  industry_06\n",
       "制药/生物工程    270  industry_10\n",
       "医疗/保健/美容   280  industry_10\n",
       "医疗器械       290  industry_10\n",
       "能源/水利      330  industry_11\n",
       "石油/化工      310  industry_11\n",
       "采掘/冶炼/矿产   320  industry_11\n",
       "环保         300  industry_11\n",
       "新能源        490  industry_11\n",
       "专业服务       120  industry_07\n",
       "中介服务       110  industry_07\n",
       "外包服务       440  industry_07\n",
       "检测/认证      450  industry_07\n",
       "餐饮/酒旅/服务   230  industry_07\n",
       "文体娱乐       260  industry_07\n",
       "租赁服务       510  industry_07\n",
       "广告/市场/会展   070  industry_08\n",
       "影视文化       170  industry_08\n",
       "教育培训       380  industry_08\n",
       "交通/物流/运输   250  industry_09\n",
       "贸易/进出口     160  industry_09\n",
       "航空/航天      480  industry_09\n",
       "政务/公共服务    390  industry_12\n",
       "农林牧渔       410  industry_12\n",
       "其他行业       400  industry_12"
      ]
     },
     "execution_count": 45,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "行业分类代号={k:行业参数拆解(v)['industryType']  for k,v in 行业字典.items()}\n",
    "行业分类代号\n",
    "行业代号拆解={k:行业参数拆解(v)['industries']  for k,v in 行业字典.items()}\n",
    "行业代号拆解\n",
    "行业分类代号={k:行业参数拆解(v)['industryType']  for k,v in 行业字典.items()}\n",
    "行业分类代号\n",
    "行业分类代号拆解=pd.DataFrame({k:行业参数拆解(v)['industryType']  for k,v in 行业字典.items()})\n",
    "cf=行业分类代号拆解.T.rename(columns={0:\"行业大类代号\"})\n",
    "cf\n",
    "ef=pd.DataFrame(行业代号拆解)\n",
    "hf=ef.T.rename(columns={0:\"行业代号\"})\n",
    "hf=hf.assign(行业大类代号=cf['行业大类代号'])\n",
    "hf"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 151,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "{'industryType': ['industry_09'],\n",
       " 'key': ['销售经理'],\n",
       " 'init': ['-1'],\n",
       " 'searchType': ['1'],\n",
       " 'headckid': ['aa4a3ef545437f22'],\n",
       " 'flushckid': ['1'],\n",
       " 'fromSearchBtn': ['2'],\n",
       " 'sortFlag': ['15'],\n",
       " 'ckid': ['bce53da97cf10328'],\n",
       " 'industries': ['160'],\n",
       " 'siTag': ['bFGQTbwE_AAQSb-u11jrBw~fA9rXquZc5IkJpXC-Ycixw'],\n",
       " 'd_sfrom': ['search_prime'],\n",
       " 'd_ckId': ['591ebc1760fee953b72353bace17e6cc'],\n",
       " 'd_curPage': ['0'],\n",
       " 'd_pageSize': ['40'],\n",
       " 'd_headId': ['591ebc1760fee953b72353bace17e6cc']}"
      ]
     },
     "execution_count": 151,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "def 行业参数调整(industryType,industries,key):\n",
    "    参数=行业参数.copy()\n",
    "    参数['industryType']=industryType\n",
    "    参数['industries']=industries\n",
    "    参数['key']=key\n",
    "    return 参数\n",
    "#k:行业参数调整(industryType=['industry_09'],industries=[],\n",
    "行业_keyword=行业参数调整(industryType=['industry_09'],industries=['160'],key=['销售经理'])\n",
    "行业_keyword\n",
    "# 行业_keyword_调整={k:key=['销售经理'])for k,v in 行业代号拆解.items()}\n",
    "# 行业_keyword_调整"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## 翻页"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 152,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "{0: {'industryType': ['industry_01'],\n",
       "  'key': ['产品经理'],\n",
       "  'init': ['-1'],\n",
       "  'searchType': ['1'],\n",
       "  'headckid': ['aa4a3ef545437f22'],\n",
       "  'fromSearchBtn': ['2'],\n",
       "  'sortFlag': ['15'],\n",
       "  'ckid': ['9f6a31509adde9d9°radeFlag=0'],\n",
       "  'industries': ['160'],\n",
       "  'siTag': ['bFGQTbwE_AAQSb-u11jrBw~1p1Hf6Iytm4nd3ac31P45g'],\n",
       "  'd_sfrom': ['search_prime'],\n",
       "  'd_ckId': ['217edde6dd80f189ae9afcf4b5be61f8'],\n",
       "  'd_curPage': ['0'],\n",
       "  'd_pageSize': ['40'],\n",
       "  'd_headId': ['591ebc1760fee953b72353bace17e6cc'],\n",
       "  'curPage': ['1'],\n",
       "  'curPage_int': [0]},\n",
       " 1: {'industryType': ['industry_01'],\n",
       "  'key': ['产品经理'],\n",
       "  'init': ['-1'],\n",
       "  'searchType': ['1'],\n",
       "  'headckid': ['aa4a3ef545437f22'],\n",
       "  'fromSearchBtn': ['2'],\n",
       "  'sortFlag': ['15'],\n",
       "  'ckid': ['3cf484d94a4ced28°radeFlag=0'],\n",
       "  'industries': ['160'],\n",
       "  'siTag': ['bFGQTbwE_AAQSb-u11jrBw~1p1Hf6Iytm4nd3ac31P45g'],\n",
       "  'd_sfrom': ['search_prime'],\n",
       "  'd_ckId': ['317717b3ba4c65f468596fba3afaf680'],\n",
       "  'd_curPage': ['0'],\n",
       "  'd_pageSize': ['40'],\n",
       "  'd_headId': ['591ebc1760fee953b72353bace17e6cc'],\n",
       "  'curPage': ['1'],\n",
       "  'curPage_int': [1]},\n",
       " 2: {'industryType': ['industry_01'],\n",
       "  'key': ['产品经理'],\n",
       "  'init': ['-1'],\n",
       "  'searchType': ['1'],\n",
       "  'headckid': ['aa4a3ef545437f22'],\n",
       "  'fromSearchBtn': ['2'],\n",
       "  'sortFlag': ['15'],\n",
       "  'ckid': ['42156608b4c49881°radeFlag=0'],\n",
       "  'industries': ['160'],\n",
       "  'siTag': ['bFGQTbwE_AAQSb-u11jrBw~1p1Hf6Iytm4nd3ac31P45g'],\n",
       "  'd_sfrom': ['search_prime'],\n",
       "  'd_ckId': ['77c96a280c8fff948fdaa5e9f36c5166'],\n",
       "  'd_curPage': ['0'],\n",
       "  'd_pageSize': ['40'],\n",
       "  'd_headId': ['591ebc1760fee953b72353bace17e6cc'],\n",
       "  'curPage': ['1'],\n",
       "  'curPage_int': [2]},\n",
       " 3: {'industryType': ['industry_01'],\n",
       "  'key': ['产品经理'],\n",
       "  'init': ['-1'],\n",
       "  'searchType': ['1'],\n",
       "  'headckid': ['aa4a3ef545437f22'],\n",
       "  'fromSearchBtn': ['2'],\n",
       "  'sortFlag': ['15'],\n",
       "  'ckid': ['e685c890ffd4707a°radeFlag=0'],\n",
       "  'industries': ['160'],\n",
       "  'siTag': ['bFGQTbwE_AAQSb-u11jrBw~1p1Hf6Iytm4nd3ac31P45g'],\n",
       "  'd_sfrom': ['search_prime'],\n",
       "  'd_ckId': ['f0458d160a9a4ae0a823cdd5232270fe'],\n",
       "  'd_curPage': ['0'],\n",
       "  'd_pageSize': ['40'],\n",
       "  'd_headId': ['591ebc1760fee953b72353bace17e6cc'],\n",
       "  'curPage': ['1'],\n",
       "  'curPage_int': [3]},\n",
       " 4: {'industryType': ['industry_01'],\n",
       "  'key': ['产品经理'],\n",
       "  'init': ['-1'],\n",
       "  'searchType': ['1'],\n",
       "  'headckid': ['aa4a3ef545437f22'],\n",
       "  'fromSearchBtn': ['2'],\n",
       "  'sortFlag': ['15'],\n",
       "  'ckid': ['ee43ae09481dd7d0°radeFlag=0'],\n",
       "  'industries': ['160'],\n",
       "  'siTag': ['bFGQTbwE_AAQSb-u11jrBw~1p1Hf6Iytm4nd3ac31P45g'],\n",
       "  'd_sfrom': ['search_prime'],\n",
       "  'd_ckId': ['9fbcc4a70a0b133ae3a77c41d666e131'],\n",
       "  'd_curPage': ['0'],\n",
       "  'd_pageSize': ['40'],\n",
       "  'd_headId': ['591ebc1760fee953b72353bace17e6cc'],\n",
       "  'curPage': ['1'],\n",
       "  'curPage_int': [4]},\n",
       " 5: {'industryType': ['industry_01'],\n",
       "  'key': ['产品经理'],\n",
       "  'init': ['-1'],\n",
       "  'searchType': ['1'],\n",
       "  'headckid': ['aa4a3ef545437f22'],\n",
       "  'fromSearchBtn': ['2'],\n",
       "  'sortFlag': ['15'],\n",
       "  'ckid': ['73ca13aa82a7ed86°radeFlag=0'],\n",
       "  'industries': ['160'],\n",
       "  'siTag': ['bFGQTbwE_AAQSb-u11jrBw~1p1Hf6Iytm4nd3ac31P45g'],\n",
       "  'd_sfrom': ['search_prime'],\n",
       "  'd_ckId': ['7da0e50ca267ebb1ea808fa984594708'],\n",
       "  'd_curPage': ['0'],\n",
       "  'd_pageSize': ['40'],\n",
       "  'd_headId': ['591ebc1760fee953b72353bace17e6cc'],\n",
       "  'curPage': ['1'],\n",
       "  'curPage_int': [5]},\n",
       " 6: {'industryType': ['industry_01'],\n",
       "  'key': ['产品经理'],\n",
       "  'init': ['-1'],\n",
       "  'searchType': ['1'],\n",
       "  'headckid': ['aa4a3ef545437f22'],\n",
       "  'fromSearchBtn': ['2'],\n",
       "  'sortFlag': ['15'],\n",
       "  'ckid': ['e8b6e7fca769610a°radeFlag=0'],\n",
       "  'industries': ['160'],\n",
       "  'siTag': ['bFGQTbwE_AAQSb-u11jrBw~1p1Hf6Iytm4nd3ac31P45g'],\n",
       "  'd_sfrom': ['search_prime'],\n",
       "  'd_ckId': ['fce1f45feab5d9f2e8f852df86d84310'],\n",
       "  'd_curPage': ['0'],\n",
       "  'd_pageSize': ['40'],\n",
       "  'd_headId': ['591ebc1760fee953b72353bace17e6cc'],\n",
       "  'curPage': ['1'],\n",
       "  'curPage_int': [6]},\n",
       " 7: {'industryType': ['industry_01'],\n",
       "  'key': ['产品经理'],\n",
       "  'init': ['-1'],\n",
       "  'searchType': ['1'],\n",
       "  'headckid': ['aa4a3ef545437f22'],\n",
       "  'fromSearchBtn': ['2'],\n",
       "  'sortFlag': ['15'],\n",
       "  'ckid': ['ea9d686bc5bb7b22°radeFlag=0'],\n",
       "  'industries': ['160'],\n",
       "  'siTag': ['bFGQTbwE_AAQSb-u11jrBw~1p1Hf6Iytm4nd3ac31P45g'],\n",
       "  'd_sfrom': ['search_prime'],\n",
       "  'd_ckId': ['5230882e1e99a8bd714b519dcb50a326'],\n",
       "  'd_curPage': ['0'],\n",
       "  'd_pageSize': ['40'],\n",
       "  'd_headId': ['591ebc1760fee953b72353bace17e6cc'],\n",
       "  'curPage': ['1'],\n",
       "  'curPage_int': [7]},\n",
       " 8: {'industryType': ['industry_01'],\n",
       "  'key': ['产品经理'],\n",
       "  'init': ['-1'],\n",
       "  'searchType': ['1'],\n",
       "  'headckid': ['aa4a3ef545437f22'],\n",
       "  'fromSearchBtn': ['2'],\n",
       "  'sortFlag': ['15'],\n",
       "  'ckid': ['4f3cb014a6355a1e°radeFlag=0'],\n",
       "  'industries': ['160'],\n",
       "  'siTag': ['bFGQTbwE_AAQSb-u11jrBw~1p1Hf6Iytm4nd3ac31P45g'],\n",
       "  'd_sfrom': ['search_prime'],\n",
       "  'd_ckId': ['62473215638bc77b98daeffeb89043ce'],\n",
       "  'd_curPage': ['0'],\n",
       "  'd_pageSize': ['40'],\n",
       "  'd_headId': ['591ebc1760fee953b72353bace17e6cc'],\n",
       "  'curPage': ['1'],\n",
       "  'curPage_int': [8]},\n",
       " 9: {'industryType': ['industry_01'],\n",
       "  'key': ['产品经理'],\n",
       "  'init': ['-1'],\n",
       "  'searchType': ['1'],\n",
       "  'headckid': ['aa4a3ef545437f22'],\n",
       "  'fromSearchBtn': ['2'],\n",
       "  'sortFlag': ['15'],\n",
       "  'ckid': ['7c2ef68235dc9aec°radeFlag=0'],\n",
       "  'industries': ['160'],\n",
       "  'siTag': ['bFGQTbwE_AAQSb-u11jrBw~1p1Hf6Iytm4nd3ac31P45g'],\n",
       "  'd_sfrom': ['search_prime'],\n",
       "  'd_ckId': ['ea1d73203a5c98049392b8916720da0a'],\n",
       "  'd_curPage': ['0'],\n",
       "  'd_pageSize': ['40'],\n",
       "  'd_headId': ['591ebc1760fee953b72353bace17e6cc'],\n",
       "  'curPage': ['1'],\n",
       "  'curPage_int': [9]}}"
      ]
     },
     "execution_count": 152,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "def 翻页_参数拆解(url):\n",
    "        sixpart=urlparse(url)\n",
    "        out=parse_qs(sixpart.query)\n",
    "        return out\n",
    "\n",
    "\n",
    "行业url =\"https://www.liepin.com/zhaopin/?isAnalysis=&dqs=&pubTime=&salary=&compIds=&subIndustry=&industryType=industry_01&compscale=&key=%E6%95%B0%E6%8D%AE%E5%88%86%E6%9E%90%E5%B8%88&init=-1&searchType=1&headckid=aa4a3ef545437f22&flushckid=1&compkind=&fromSearchBtn=2&sortFlag=15&ckid=8bc9e5a71fd77d33&jobKind=&industries=040&clean_condition=&siTag=bFGQTbwE_AAQSb-u11jrBw%7EfA9rXquZc5IkJpXC-Ycixw&d_sfrom=search_prime&d_ckId=591ebc1760fee953b72353bace17e6cc&d_curPage=0&d_pageSize=40&d_headId=591ebc1760fee953b72353bace17e6cc\"\n",
    "def  翻页url(url,industryType,industries,key,curPage_int):\n",
    "    r=session.get(url)\n",
    "    xpath_翻页a = '//div[@class=\"pagerbar\"]/a[starts-with(@href,\"/zhaopin\")]'\n",
    "    翻页url={x.text:x.xpath('//@href')[0] for x in r.html.xpath(xpath_翻页a)}\n",
    "    翻页url\n",
    "    href_翻页=[x.xpath('//@href')[0] for x in r.html.xpath(xpath_翻页a)]\n",
    "    df=pd.DataFrame([urlparse(x) for x in href_翻页 ])\n",
    "    df_qs=pd.DataFrame([{ k:v[0] for k,v in parse_qs(x).items()}for x in df['query']])\n",
    "    df_qs = df_qs.assign (curPage_int=df_qs.curPage.astype(int)) \n",
    "    df_qs\n",
    "    长度=int(df_qs.curPage_int.max()+1)\n",
    "    翻页_参数模板=翻页_参数拆解(href_翻页[0])\n",
    "    参数=翻页_参数模板.copy()\n",
    "    参数['industryType']=industryType\n",
    "    参数['industries']=industries\n",
    "    参数['key']=key\n",
    "    参数['curPage_int']=curPage_int\n",
    "    return 参数\n",
    "# e=翻页url(url,industryType=['industry_01'],industries=['010'],key=['产品经理'])\n",
    "# e\n",
    "翻页_参数={i:翻页url(行业url,industryType=['industry_01'],industries=['160'],key=['产品经理'],curPage_int = [i]  )\n",
    "               for i in  range(0,长度)\n",
    "      }\n",
    "# # 指定公司_关键词_翻页参数=翻页_参数调整(key=['数据挖掘'],compIds=['7983148'],curPage_int= [i])\n",
    "# #                                    for i in  range(0,长度)\n",
    "# #                                   }\n",
    "翻页_参数"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## 指定行业类别搜索多个关键词进行爬取"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 153,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "用户体验 10\n",
      "UX 10\n",
      "产品需求 10\n",
      "PRD 10\n"
     ]
    },
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>index</th>\n",
       "      <th>edu</th>\n",
       "      <th>经验</th>\n",
       "      <th>薪水</th>\n",
       "      <th>时间</th>\n",
       "      <th>职称</th>\n",
       "      <th>公司地点</th>\n",
       "      <th>公司名称</th>\n",
       "      <th>链结</th>\n",
       "      <th>公司URL</th>\n",
       "      <th>keyword</th>\n",
       "      <th>curPage</th>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>序</th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>0</td>\n",
       "      <td>本科及以上</td>\n",
       "      <td>5-10年</td>\n",
       "      <td>25-50k·15薪</td>\n",
       "      <td>2020年04月23日</td>\n",
       "      <td>用户体验经理</td>\n",
       "      <td>深圳</td>\n",
       "      <td>某上市集团电子公司</td>\n",
       "      <td>https://www.liepin.com/a/19720077.shtml</td>\n",
       "      <td></td>\n",
       "      <td>用户体验</td>\n",
       "      <td>0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td>1</td>\n",
       "      <td>学历不限</td>\n",
       "      <td>5-10年</td>\n",
       "      <td>40-70k·12薪</td>\n",
       "      <td>2020年04月23日</td>\n",
       "      <td>用户体验设计（前端负责人）</td>\n",
       "      <td>上海,北京</td>\n",
       "      <td>某知名网络科技公司</td>\n",
       "      <td>https://www.liepin.com/a/19699449.shtml</td>\n",
       "      <td></td>\n",
       "      <td>用户体验</td>\n",
       "      <td>0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>2</td>\n",
       "      <td>统招本科</td>\n",
       "      <td>5-10年</td>\n",
       "      <td>25-40k·12薪</td>\n",
       "      <td>2020年04月23日</td>\n",
       "      <td>电商用户体验NPS提升岗</td>\n",
       "      <td>上海-黄浦区</td>\n",
       "      <td>某互联网有限公司</td>\n",
       "      <td>https://www.liepin.com/a/19655709.shtml</td>\n",
       "      <td></td>\n",
       "      <td>用户体验</td>\n",
       "      <td>0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>3</th>\n",
       "      <td>3</td>\n",
       "      <td>统招本科</td>\n",
       "      <td>5-10年</td>\n",
       "      <td>20-40k·16薪</td>\n",
       "      <td>2020年04月23日</td>\n",
       "      <td>ued用户体验设计师</td>\n",
       "      <td>北京</td>\n",
       "      <td>某知名大厂</td>\n",
       "      <td>https://www.liepin.com/a/19628499.shtml</td>\n",
       "      <td></td>\n",
       "      <td>用户体验</td>\n",
       "      <td>0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>4</th>\n",
       "      <td>4</td>\n",
       "      <td>统招本科</td>\n",
       "      <td>5-10年</td>\n",
       "      <td>40-60k·12薪</td>\n",
       "      <td>2020年04月23日</td>\n",
       "      <td>用户调研/体验运营专家</td>\n",
       "      <td>上海</td>\n",
       "      <td>大型零售连锁上市公司</td>\n",
       "      <td>https://www.liepin.com/a/19624729.shtml</td>\n",
       "      <td></td>\n",
       "      <td>用户体验</td>\n",
       "      <td>0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>...</th>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1595</th>\n",
       "      <td>35</td>\n",
       "      <td>统招本科</td>\n",
       "      <td>5-10年</td>\n",
       "      <td>20-30k·12薪</td>\n",
       "      <td>2020年04月23日</td>\n",
       "      <td>C端产品经理</td>\n",
       "      <td></td>\n",
       "      <td>北京友聚四海网络科技有限公司</td>\n",
       "      <td>https://www.liepin.com/job/1927493367.shtml</td>\n",
       "      <td>https://www.liepin.com/company/9727158/</td>\n",
       "      <td>PRD</td>\n",
       "      <td>9</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1596</th>\n",
       "      <td>36</td>\n",
       "      <td>统招本科</td>\n",
       "      <td>5-10年</td>\n",
       "      <td>20-40k·12薪</td>\n",
       "      <td>2020年04月23日</td>\n",
       "      <td>解决方案与产品交付专家（公共安全）</td>\n",
       "      <td>杭州</td>\n",
       "      <td>大箴(杭州)科技有限公司</td>\n",
       "      <td>https://www.liepin.com/job/1927491431.shtml</td>\n",
       "      <td>https://www.liepin.com/company/9692929/</td>\n",
       "      <td>PRD</td>\n",
       "      <td>9</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1597</th>\n",
       "      <td>37</td>\n",
       "      <td>统招本科</td>\n",
       "      <td>3-5年</td>\n",
       "      <td>15-30k·12薪</td>\n",
       "      <td>2020年04月23日</td>\n",
       "      <td>产品经理（toG 公共安全）</td>\n",
       "      <td>杭州</td>\n",
       "      <td>大箴(杭州)科技有限公司</td>\n",
       "      <td>https://www.liepin.com/job/1927491273.shtml</td>\n",
       "      <td>https://www.liepin.com/company/9692929/</td>\n",
       "      <td>PRD</td>\n",
       "      <td>9</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1598</th>\n",
       "      <td>38</td>\n",
       "      <td>本科及以上</td>\n",
       "      <td>3-5年</td>\n",
       "      <td>20-40k·16薪</td>\n",
       "      <td>2020年04月23日</td>\n",
       "      <td>会员产品经理</td>\n",
       "      <td>上海-浦东新区</td>\n",
       "      <td>上海基分文化传播</td>\n",
       "      <td>https://www.liepin.com/job/1927466755.shtml</td>\n",
       "      <td>https://www.liepin.com/company/8895584/</td>\n",
       "      <td>PRD</td>\n",
       "      <td>9</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1599</th>\n",
       "      <td>39</td>\n",
       "      <td>本科及以上</td>\n",
       "      <td>5-10年</td>\n",
       "      <td>13-20k·12薪</td>\n",
       "      <td>2020年04月23日</td>\n",
       "      <td>产品经理</td>\n",
       "      <td>上海-中山公园</td>\n",
       "      <td>永辉青禾商业保理(重庆)有限公司</td>\n",
       "      <td>https://www.liepin.com/job/1927462853.shtml</td>\n",
       "      <td>https://www.liepin.com/company/10111627/</td>\n",
       "      <td>PRD</td>\n",
       "      <td>9</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "<p>1600 rows × 12 columns</p>\n",
       "</div>"
      ],
      "text/plain": [
       "      index    edu     经验          薪水           时间                 职称  \\\n",
       "序                                                                       \n",
       "0         0  本科及以上  5-10年  25-50k·15薪  2020年04月23日             用户体验经理   \n",
       "1         1   学历不限  5-10年  40-70k·12薪  2020年04月23日      用户体验设计（前端负责人）   \n",
       "2         2   统招本科  5-10年  25-40k·12薪  2020年04月23日       电商用户体验NPS提升岗   \n",
       "3         3   统招本科  5-10年  20-40k·16薪  2020年04月23日         ued用户体验设计师   \n",
       "4         4   统招本科  5-10年  40-60k·12薪  2020年04月23日        用户调研/体验运营专家   \n",
       "...     ...    ...    ...         ...          ...                ...   \n",
       "1595     35   统招本科  5-10年  20-30k·12薪  2020年04月23日             C端产品经理   \n",
       "1596     36   统招本科  5-10年  20-40k·12薪  2020年04月23日  解决方案与产品交付专家（公共安全）   \n",
       "1597     37   统招本科   3-5年  15-30k·12薪  2020年04月23日     产品经理（toG 公共安全）   \n",
       "1598     38  本科及以上   3-5年  20-40k·16薪  2020年04月23日             会员产品经理   \n",
       "1599     39  本科及以上  5-10年  13-20k·12薪  2020年04月23日               产品经理   \n",
       "\n",
       "         公司地点              公司名称                                           链结  \\\n",
       "序                                                                              \n",
       "0          深圳         某上市集团电子公司      https://www.liepin.com/a/19720077.shtml   \n",
       "1       上海,北京         某知名网络科技公司      https://www.liepin.com/a/19699449.shtml   \n",
       "2      上海-黄浦区          某互联网有限公司      https://www.liepin.com/a/19655709.shtml   \n",
       "3          北京             某知名大厂      https://www.liepin.com/a/19628499.shtml   \n",
       "4          上海        大型零售连锁上市公司      https://www.liepin.com/a/19624729.shtml   \n",
       "...       ...               ...                                          ...   \n",
       "1595             北京友聚四海网络科技有限公司  https://www.liepin.com/job/1927493367.shtml   \n",
       "1596       杭州      大箴(杭州)科技有限公司  https://www.liepin.com/job/1927491431.shtml   \n",
       "1597       杭州      大箴(杭州)科技有限公司  https://www.liepin.com/job/1927491273.shtml   \n",
       "1598  上海-浦东新区          上海基分文化传播  https://www.liepin.com/job/1927466755.shtml   \n",
       "1599  上海-中山公园  永辉青禾商业保理(重庆)有限公司  https://www.liepin.com/job/1927462853.shtml   \n",
       "\n",
       "                                         公司URL keyword  curPage  \n",
       "序                                                                \n",
       "0                                                 用户体验        0  \n",
       "1                                                 用户体验        0  \n",
       "2                                                 用户体验        0  \n",
       "3                                                 用户体验        0  \n",
       "4                                                 用户体验        0  \n",
       "...                                        ...     ...      ...  \n",
       "1595   https://www.liepin.com/company/9727158/     PRD        9  \n",
       "1596   https://www.liepin.com/company/9692929/     PRD        9  \n",
       "1597   https://www.liepin.com/company/9692929/     PRD        9  \n",
       "1598   https://www.liepin.com/company/8895584/     PRD        9  \n",
       "1599  https://www.liepin.com/company/10111627/     PRD        9  \n",
       "\n",
       "[1600 rows x 12 columns]"
      ]
     },
     "execution_count": 153,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "import time\n",
    "from random import random\n",
    "from requests_html import HTMLSession\n",
    "session =HTMLSession()\n",
    "url=\"https://www.liepin.com/zhaopin/\"\n",
    "r=session.get(url)\n",
    "keywords = ['用户体验','UX','产品需求','PRD']\n",
    "list_df=list()\n",
    "for key in keywords:\n",
    "    翻页_参数={i:翻页url(行业url,industryType=['industry_01'],industries=['040'],key=[key],curPage_int = [i]  )\n",
    "               for i in  range(0,长度)\n",
    "      }\n",
    "    print (key,长度)\n",
    "    for k,v in  翻页_参数.items():\n",
    "        payload = v\n",
    "        df = requests_liepin( url, params = payload)\n",
    "#         time.sleep(1+4*random())  #放慢脚步 3-7秒, 平均约5秒\n",
    "#         ## 备份\n",
    "#         df.to_csv(\"20春_Web数据挖掘_week04_liepin_{key}_{k}.tsv\"\\\n",
    "#                   .format(key=key, k=k), sep=\"\\t\", encoding=\"utf8\")\n",
    "\n",
    "        df = df.assign (keyword = key)  # 区分  keyword    \n",
    "        df = df.assign (curPage = k)  # 区分  curPage\n",
    "        \n",
    "        list_df.append(df)\n",
    "        \n",
    "df_all = pd.concat(list_df).reset_index()\n",
    "df_all.index.name = '序'\n",
    "df_all"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## 多个行业类别搜索一个关键词"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 154,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "销售经理 ['industry_01'] ['040'] 10\n",
      "销售经理 ['industry_01'] ['420'] 10\n",
      "销售经理 ['industry_01'] ['010'] 10\n",
      "销售经理 ['industry_01'] ['030'] 10\n",
      "销售经理 ['industry_01'] ['050'] 10\n",
      "销售经理 ['industry_01'] ['060'] 10\n",
      "销售经理 ['industry_01'] ['020'] 10\n",
      "销售经理 ['industry_01'] ['080'] 10\n",
      "销售经理 ['industry_01'] ['100'] 10\n",
      "销售经理 ['industry_01'] ['090'] 10\n",
      "销售经理 ['industry_01'] ['130'] 10\n"
     ]
    },
    {
     "ename": "KeyboardInterrupt",
     "evalue": "",
     "output_type": "error",
     "traceback": [
      "\u001b[1;31m---------------------------------------------------------------------------\u001b[0m",
      "\u001b[1;31mKeyboardInterrupt\u001b[0m                         Traceback (most recent call last)",
      "\u001b[1;32m<ipython-input-154-72bfe8aa0413>\u001b[0m in \u001b[0;36m<module>\u001b[1;34m\u001b[0m\n\u001b[0;32m     15\u001b[0m             \u001b[1;32mfor\u001b[0m \u001b[0mkey\u001b[0m \u001b[1;32min\u001b[0m \u001b[0mkeywords\u001b[0m\u001b[1;33m:\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0;32m     16\u001b[0m                 翻页_参数={i:翻页url(行业url,industryType=[industryType],industries=[industries],key=[key],curPage_int = [i]  )\n\u001b[1;32m---> 17\u001b[1;33m                \u001b[1;32mfor\u001b[0m \u001b[0mi\u001b[0m \u001b[1;32min\u001b[0m  \u001b[0mrange\u001b[0m\u001b[1;33m(\u001b[0m\u001b[1;36m0\u001b[0m\u001b[1;33m,\u001b[0m\u001b[0m长度\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0m\u001b[0;32m     18\u001b[0m       }\n\u001b[0;32m     19\u001b[0m                 \u001b[0mprint\u001b[0m \u001b[1;33m(\u001b[0m\u001b[0mkey\u001b[0m\u001b[1;33m,\u001b[0m\u001b[0mindustryType\u001b[0m\u001b[1;33m,\u001b[0m\u001b[0mindustries\u001b[0m\u001b[1;33m,\u001b[0m\u001b[0m长度\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n",
      "\u001b[1;32m<ipython-input-154-72bfe8aa0413>\u001b[0m in \u001b[0;36m<dictcomp>\u001b[1;34m(.0)\u001b[0m\n\u001b[0;32m     15\u001b[0m             \u001b[1;32mfor\u001b[0m \u001b[0mkey\u001b[0m \u001b[1;32min\u001b[0m \u001b[0mkeywords\u001b[0m\u001b[1;33m:\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0;32m     16\u001b[0m                 翻页_参数={i:翻页url(行业url,industryType=[industryType],industries=[industries],key=[key],curPage_int = [i]  )\n\u001b[1;32m---> 17\u001b[1;33m                \u001b[1;32mfor\u001b[0m \u001b[0mi\u001b[0m \u001b[1;32min\u001b[0m  \u001b[0mrange\u001b[0m\u001b[1;33m(\u001b[0m\u001b[1;36m0\u001b[0m\u001b[1;33m,\u001b[0m\u001b[0m长度\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0m\u001b[0;32m     18\u001b[0m       }\n\u001b[0;32m     19\u001b[0m                 \u001b[0mprint\u001b[0m \u001b[1;33m(\u001b[0m\u001b[0mkey\u001b[0m\u001b[1;33m,\u001b[0m\u001b[0mindustryType\u001b[0m\u001b[1;33m,\u001b[0m\u001b[0mindustries\u001b[0m\u001b[1;33m,\u001b[0m\u001b[0m长度\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n",
      "\u001b[1;32m<ipython-input-152-cf0ff23f5955>\u001b[0m in \u001b[0;36m翻页url\u001b[1;34m(url, industryType, industries, key, curPage_int)\u001b[0m\n\u001b[0;32m      7\u001b[0m \u001b[0m行业url\u001b[0m \u001b[1;33m=\u001b[0m\u001b[1;34m\"https://www.liepin.com/zhaopin/?isAnalysis=&dqs=&pubTime=&salary=&compIds=&subIndustry=&industryType=industry_01&compscale=&key=%E6%95%B0%E6%8D%AE%E5%88%86%E6%9E%90%E5%B8%88&init=-1&searchType=1&headckid=aa4a3ef545437f22&flushckid=1&compkind=&fromSearchBtn=2&sortFlag=15&ckid=8bc9e5a71fd77d33&jobKind=&industries=040&clean_condition=&siTag=bFGQTbwE_AAQSb-u11jrBw%7EfA9rXquZc5IkJpXC-Ycixw&d_sfrom=search_prime&d_ckId=591ebc1760fee953b72353bace17e6cc&d_curPage=0&d_pageSize=40&d_headId=591ebc1760fee953b72353bace17e6cc\"\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0;32m      8\u001b[0m \u001b[1;32mdef\u001b[0m  \u001b[0m翻页url\u001b[0m\u001b[1;33m(\u001b[0m\u001b[0murl\u001b[0m\u001b[1;33m,\u001b[0m\u001b[0mindustryType\u001b[0m\u001b[1;33m,\u001b[0m\u001b[0mindustries\u001b[0m\u001b[1;33m,\u001b[0m\u001b[0mkey\u001b[0m\u001b[1;33m,\u001b[0m\u001b[0mcurPage_int\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m:\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[1;32m----> 9\u001b[1;33m     \u001b[0mr\u001b[0m\u001b[1;33m=\u001b[0m\u001b[0msession\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0mget\u001b[0m\u001b[1;33m(\u001b[0m\u001b[0murl\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0m\u001b[0;32m     10\u001b[0m     \u001b[0mxpath_翻页a\u001b[0m \u001b[1;33m=\u001b[0m \u001b[1;34m'//div[@class=\"pagerbar\"]/a[starts-with(@href,\"/zhaopin\")]'\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0;32m     11\u001b[0m     \u001b[0m翻页url\u001b[0m\u001b[1;33m=\u001b[0m\u001b[1;33m{\u001b[0m\u001b[0mx\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0mtext\u001b[0m\u001b[1;33m:\u001b[0m\u001b[0mx\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0mxpath\u001b[0m\u001b[1;33m(\u001b[0m\u001b[1;34m'//@href'\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m[\u001b[0m\u001b[1;36m0\u001b[0m\u001b[1;33m]\u001b[0m \u001b[1;32mfor\u001b[0m \u001b[0mx\u001b[0m \u001b[1;32min\u001b[0m \u001b[0mr\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0mhtml\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0mxpath\u001b[0m\u001b[1;33m(\u001b[0m\u001b[0mxpath_翻页a\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m}\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n",
      "\u001b[1;32mC:\\ProgramData\\Anaconda3\\lib\\site-packages\\requests\\sessions.py\u001b[0m in \u001b[0;36mget\u001b[1;34m(self, url, **kwargs)\u001b[0m\n\u001b[0;32m    544\u001b[0m \u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0;32m    545\u001b[0m         \u001b[0mkwargs\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0msetdefault\u001b[0m\u001b[1;33m(\u001b[0m\u001b[1;34m'allow_redirects'\u001b[0m\u001b[1;33m,\u001b[0m \u001b[1;32mTrue\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[1;32m--> 546\u001b[1;33m         \u001b[1;32mreturn\u001b[0m \u001b[0mself\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0mrequest\u001b[0m\u001b[1;33m(\u001b[0m\u001b[1;34m'GET'\u001b[0m\u001b[1;33m,\u001b[0m \u001b[0murl\u001b[0m\u001b[1;33m,\u001b[0m \u001b[1;33m**\u001b[0m\u001b[0mkwargs\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0m\u001b[0;32m    547\u001b[0m \u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0;32m    548\u001b[0m     \u001b[1;32mdef\u001b[0m \u001b[0moptions\u001b[0m\u001b[1;33m(\u001b[0m\u001b[0mself\u001b[0m\u001b[1;33m,\u001b[0m \u001b[0murl\u001b[0m\u001b[1;33m,\u001b[0m \u001b[1;33m**\u001b[0m\u001b[0mkwargs\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m:\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n",
      "\u001b[1;32mC:\\ProgramData\\Anaconda3\\lib\\site-packages\\requests\\sessions.py\u001b[0m in \u001b[0;36mrequest\u001b[1;34m(self, method, url, params, data, headers, cookies, files, auth, timeout, allow_redirects, proxies, hooks, stream, verify, cert, json)\u001b[0m\n\u001b[0;32m    531\u001b[0m         }\n\u001b[0;32m    532\u001b[0m         \u001b[0msend_kwargs\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0mupdate\u001b[0m\u001b[1;33m(\u001b[0m\u001b[0msettings\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[1;32m--> 533\u001b[1;33m         \u001b[0mresp\u001b[0m \u001b[1;33m=\u001b[0m \u001b[0mself\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0msend\u001b[0m\u001b[1;33m(\u001b[0m\u001b[0mprep\u001b[0m\u001b[1;33m,\u001b[0m \u001b[1;33m**\u001b[0m\u001b[0msend_kwargs\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0m\u001b[0;32m    534\u001b[0m \u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0;32m    535\u001b[0m         \u001b[1;32mreturn\u001b[0m \u001b[0mresp\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n",
      "\u001b[1;32mC:\\ProgramData\\Anaconda3\\lib\\site-packages\\requests\\sessions.py\u001b[0m in \u001b[0;36msend\u001b[1;34m(self, request, **kwargs)\u001b[0m\n\u001b[0;32m    644\u001b[0m \u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0;32m    645\u001b[0m         \u001b[1;31m# Send the request\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[1;32m--> 646\u001b[1;33m         \u001b[0mr\u001b[0m \u001b[1;33m=\u001b[0m \u001b[0madapter\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0msend\u001b[0m\u001b[1;33m(\u001b[0m\u001b[0mrequest\u001b[0m\u001b[1;33m,\u001b[0m \u001b[1;33m**\u001b[0m\u001b[0mkwargs\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0m\u001b[0;32m    647\u001b[0m \u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0;32m    648\u001b[0m         \u001b[1;31m# Total elapsed time of the request (approximately)\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n",
      "\u001b[1;32mC:\\ProgramData\\Anaconda3\\lib\\site-packages\\requests\\adapters.py\u001b[0m in \u001b[0;36msend\u001b[1;34m(self, request, stream, timeout, verify, cert, proxies)\u001b[0m\n\u001b[0;32m    447\u001b[0m                     \u001b[0mdecode_content\u001b[0m\u001b[1;33m=\u001b[0m\u001b[1;32mFalse\u001b[0m\u001b[1;33m,\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0;32m    448\u001b[0m                     \u001b[0mretries\u001b[0m\u001b[1;33m=\u001b[0m\u001b[0mself\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0mmax_retries\u001b[0m\u001b[1;33m,\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[1;32m--> 449\u001b[1;33m                     \u001b[0mtimeout\u001b[0m\u001b[1;33m=\u001b[0m\u001b[0mtimeout\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0m\u001b[0;32m    450\u001b[0m                 )\n\u001b[0;32m    451\u001b[0m \u001b[1;33m\u001b[0m\u001b[0m\n",
      "\u001b[1;32mC:\\ProgramData\\Anaconda3\\lib\\site-packages\\urllib3\\connectionpool.py\u001b[0m in \u001b[0;36murlopen\u001b[1;34m(self, method, url, body, headers, retries, redirect, assert_same_host, timeout, pool_timeout, release_conn, chunked, body_pos, **response_kw)\u001b[0m\n\u001b[0;32m    670\u001b[0m                 \u001b[0mbody\u001b[0m\u001b[1;33m=\u001b[0m\u001b[0mbody\u001b[0m\u001b[1;33m,\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0;32m    671\u001b[0m                 \u001b[0mheaders\u001b[0m\u001b[1;33m=\u001b[0m\u001b[0mheaders\u001b[0m\u001b[1;33m,\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[1;32m--> 672\u001b[1;33m                 \u001b[0mchunked\u001b[0m\u001b[1;33m=\u001b[0m\u001b[0mchunked\u001b[0m\u001b[1;33m,\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0m\u001b[0;32m    673\u001b[0m             )\n\u001b[0;32m    674\u001b[0m \u001b[1;33m\u001b[0m\u001b[0m\n",
      "\u001b[1;32mC:\\ProgramData\\Anaconda3\\lib\\site-packages\\urllib3\\connectionpool.py\u001b[0m in \u001b[0;36m_make_request\u001b[1;34m(self, conn, method, url, timeout, chunked, **httplib_request_kw)\u001b[0m\n\u001b[0;32m    419\u001b[0m                     \u001b[1;31m# Python 3 (including for exceptions like SystemExit).\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0;32m    420\u001b[0m                     \u001b[1;31m# Otherwise it looks like a bug in the code.\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[1;32m--> 421\u001b[1;33m                     \u001b[0msix\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0mraise_from\u001b[0m\u001b[1;33m(\u001b[0m\u001b[0me\u001b[0m\u001b[1;33m,\u001b[0m \u001b[1;32mNone\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0m\u001b[0;32m    422\u001b[0m         \u001b[1;32mexcept\u001b[0m \u001b[1;33m(\u001b[0m\u001b[0mSocketTimeout\u001b[0m\u001b[1;33m,\u001b[0m \u001b[0mBaseSSLError\u001b[0m\u001b[1;33m,\u001b[0m \u001b[0mSocketError\u001b[0m\u001b[1;33m)\u001b[0m \u001b[1;32mas\u001b[0m \u001b[0me\u001b[0m\u001b[1;33m:\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0;32m    423\u001b[0m             \u001b[0mself\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0m_raise_timeout\u001b[0m\u001b[1;33m(\u001b[0m\u001b[0merr\u001b[0m\u001b[1;33m=\u001b[0m\u001b[0me\u001b[0m\u001b[1;33m,\u001b[0m \u001b[0murl\u001b[0m\u001b[1;33m=\u001b[0m\u001b[0murl\u001b[0m\u001b[1;33m,\u001b[0m \u001b[0mtimeout_value\u001b[0m\u001b[1;33m=\u001b[0m\u001b[0mread_timeout\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n",
      "\u001b[1;32mC:\\ProgramData\\Anaconda3\\lib\\site-packages\\urllib3\\packages\\six.py\u001b[0m in \u001b[0;36mraise_from\u001b[1;34m(value, from_value)\u001b[0m\n",
      "\u001b[1;32mC:\\ProgramData\\Anaconda3\\lib\\site-packages\\urllib3\\connectionpool.py\u001b[0m in \u001b[0;36m_make_request\u001b[1;34m(self, conn, method, url, timeout, chunked, **httplib_request_kw)\u001b[0m\n\u001b[0;32m    414\u001b[0m                 \u001b[1;31m# Python 3\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0;32m    415\u001b[0m                 \u001b[1;32mtry\u001b[0m\u001b[1;33m:\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[1;32m--> 416\u001b[1;33m                     \u001b[0mhttplib_response\u001b[0m \u001b[1;33m=\u001b[0m \u001b[0mconn\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0mgetresponse\u001b[0m\u001b[1;33m(\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0m\u001b[0;32m    417\u001b[0m                 \u001b[1;32mexcept\u001b[0m \u001b[0mBaseException\u001b[0m \u001b[1;32mas\u001b[0m \u001b[0me\u001b[0m\u001b[1;33m:\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0;32m    418\u001b[0m                     \u001b[1;31m# Remove the TypeError from the exception chain in\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n",
      "\u001b[1;32mC:\\ProgramData\\Anaconda3\\lib\\http\\client.py\u001b[0m in \u001b[0;36mgetresponse\u001b[1;34m(self)\u001b[0m\n\u001b[0;32m   1342\u001b[0m         \u001b[1;32mtry\u001b[0m\u001b[1;33m:\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0;32m   1343\u001b[0m             \u001b[1;32mtry\u001b[0m\u001b[1;33m:\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[1;32m-> 1344\u001b[1;33m                 \u001b[0mresponse\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0mbegin\u001b[0m\u001b[1;33m(\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0m\u001b[0;32m   1345\u001b[0m             \u001b[1;32mexcept\u001b[0m \u001b[0mConnectionError\u001b[0m\u001b[1;33m:\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0;32m   1346\u001b[0m                 \u001b[0mself\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0mclose\u001b[0m\u001b[1;33m(\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n",
      "\u001b[1;32mC:\\ProgramData\\Anaconda3\\lib\\http\\client.py\u001b[0m in \u001b[0;36mbegin\u001b[1;34m(self)\u001b[0m\n\u001b[0;32m    304\u001b[0m         \u001b[1;31m# read until we get a non-100 response\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0;32m    305\u001b[0m         \u001b[1;32mwhile\u001b[0m \u001b[1;32mTrue\u001b[0m\u001b[1;33m:\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[1;32m--> 306\u001b[1;33m             \u001b[0mversion\u001b[0m\u001b[1;33m,\u001b[0m \u001b[0mstatus\u001b[0m\u001b[1;33m,\u001b[0m \u001b[0mreason\u001b[0m \u001b[1;33m=\u001b[0m \u001b[0mself\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0m_read_status\u001b[0m\u001b[1;33m(\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0m\u001b[0;32m    307\u001b[0m             \u001b[1;32mif\u001b[0m \u001b[0mstatus\u001b[0m \u001b[1;33m!=\u001b[0m \u001b[0mCONTINUE\u001b[0m\u001b[1;33m:\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0;32m    308\u001b[0m                 \u001b[1;32mbreak\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n",
      "\u001b[1;32mC:\\ProgramData\\Anaconda3\\lib\\http\\client.py\u001b[0m in \u001b[0;36m_read_status\u001b[1;34m(self)\u001b[0m\n\u001b[0;32m    265\u001b[0m \u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0;32m    266\u001b[0m     \u001b[1;32mdef\u001b[0m \u001b[0m_read_status\u001b[0m\u001b[1;33m(\u001b[0m\u001b[0mself\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m:\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[1;32m--> 267\u001b[1;33m         \u001b[0mline\u001b[0m \u001b[1;33m=\u001b[0m \u001b[0mstr\u001b[0m\u001b[1;33m(\u001b[0m\u001b[0mself\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0mfp\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0mreadline\u001b[0m\u001b[1;33m(\u001b[0m\u001b[0m_MAXLINE\u001b[0m \u001b[1;33m+\u001b[0m \u001b[1;36m1\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m,\u001b[0m \u001b[1;34m\"iso-8859-1\"\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0m\u001b[0;32m    268\u001b[0m         \u001b[1;32mif\u001b[0m \u001b[0mlen\u001b[0m\u001b[1;33m(\u001b[0m\u001b[0mline\u001b[0m\u001b[1;33m)\u001b[0m \u001b[1;33m>\u001b[0m \u001b[0m_MAXLINE\u001b[0m\u001b[1;33m:\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0;32m    269\u001b[0m             \u001b[1;32mraise\u001b[0m \u001b[0mLineTooLong\u001b[0m\u001b[1;33m(\u001b[0m\u001b[1;34m\"status line\"\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n",
      "\u001b[1;32mC:\\ProgramData\\Anaconda3\\lib\\socket.py\u001b[0m in \u001b[0;36mreadinto\u001b[1;34m(self, b)\u001b[0m\n\u001b[0;32m    587\u001b[0m         \u001b[1;32mwhile\u001b[0m \u001b[1;32mTrue\u001b[0m\u001b[1;33m:\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0;32m    588\u001b[0m             \u001b[1;32mtry\u001b[0m\u001b[1;33m:\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[1;32m--> 589\u001b[1;33m                 \u001b[1;32mreturn\u001b[0m \u001b[0mself\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0m_sock\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0mrecv_into\u001b[0m\u001b[1;33m(\u001b[0m\u001b[0mb\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0m\u001b[0;32m    590\u001b[0m             \u001b[1;32mexcept\u001b[0m \u001b[0mtimeout\u001b[0m\u001b[1;33m:\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0;32m    591\u001b[0m                 \u001b[0mself\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0m_timeout_occurred\u001b[0m \u001b[1;33m=\u001b[0m \u001b[1;32mTrue\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n",
      "\u001b[1;32mC:\\ProgramData\\Anaconda3\\lib\\site-packages\\urllib3\\contrib\\pyopenssl.py\u001b[0m in \u001b[0;36mrecv_into\u001b[1;34m(self, *args, **kwargs)\u001b[0m\n\u001b[0;32m    311\u001b[0m     \u001b[1;32mdef\u001b[0m \u001b[0mrecv_into\u001b[0m\u001b[1;33m(\u001b[0m\u001b[0mself\u001b[0m\u001b[1;33m,\u001b[0m \u001b[1;33m*\u001b[0m\u001b[0margs\u001b[0m\u001b[1;33m,\u001b[0m \u001b[1;33m**\u001b[0m\u001b[0mkwargs\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m:\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0;32m    312\u001b[0m         \u001b[1;32mtry\u001b[0m\u001b[1;33m:\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[1;32m--> 313\u001b[1;33m             \u001b[1;32mreturn\u001b[0m \u001b[0mself\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0mconnection\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0mrecv_into\u001b[0m\u001b[1;33m(\u001b[0m\u001b[1;33m*\u001b[0m\u001b[0margs\u001b[0m\u001b[1;33m,\u001b[0m \u001b[1;33m**\u001b[0m\u001b[0mkwargs\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0m\u001b[0;32m    314\u001b[0m         \u001b[1;32mexcept\u001b[0m \u001b[0mOpenSSL\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0mSSL\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0mSysCallError\u001b[0m \u001b[1;32mas\u001b[0m \u001b[0me\u001b[0m\u001b[1;33m:\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0;32m    315\u001b[0m             \u001b[1;32mif\u001b[0m \u001b[0mself\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0msuppress_ragged_eofs\u001b[0m \u001b[1;32mand\u001b[0m \u001b[0me\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0margs\u001b[0m \u001b[1;33m==\u001b[0m \u001b[1;33m(\u001b[0m\u001b[1;33m-\u001b[0m\u001b[1;36m1\u001b[0m\u001b[1;33m,\u001b[0m \u001b[1;34m\"Unexpected EOF\"\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m:\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n",
      "\u001b[1;32mC:\\ProgramData\\Anaconda3\\lib\\site-packages\\OpenSSL\\SSL.py\u001b[0m in \u001b[0;36mrecv_into\u001b[1;34m(self, buffer, nbytes, flags)\u001b[0m\n\u001b[0;32m   1837\u001b[0m             \u001b[0mresult\u001b[0m \u001b[1;33m=\u001b[0m \u001b[0m_lib\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0mSSL_peek\u001b[0m\u001b[1;33m(\u001b[0m\u001b[0mself\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0m_ssl\u001b[0m\u001b[1;33m,\u001b[0m \u001b[0mbuf\u001b[0m\u001b[1;33m,\u001b[0m \u001b[0mnbytes\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0;32m   1838\u001b[0m         \u001b[1;32melse\u001b[0m\u001b[1;33m:\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[1;32m-> 1839\u001b[1;33m             \u001b[0mresult\u001b[0m \u001b[1;33m=\u001b[0m \u001b[0m_lib\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0mSSL_read\u001b[0m\u001b[1;33m(\u001b[0m\u001b[0mself\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0m_ssl\u001b[0m\u001b[1;33m,\u001b[0m \u001b[0mbuf\u001b[0m\u001b[1;33m,\u001b[0m \u001b[0mnbytes\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0m\u001b[0;32m   1840\u001b[0m         \u001b[0mself\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0m_raise_ssl_error\u001b[0m\u001b[1;33m(\u001b[0m\u001b[0mself\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0m_ssl\u001b[0m\u001b[1;33m,\u001b[0m \u001b[0mresult\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0;32m   1841\u001b[0m \u001b[1;33m\u001b[0m\u001b[0m\n",
      "\u001b[1;31mKeyboardInterrupt\u001b[0m: "
     ]
    }
   ],
   "source": [
    "import time\n",
    "from random import random\n",
    "from requests_html import HTMLSession\n",
    "session =HTMLSession()\n",
    "url=\"https://www.liepin.com/zhaopin/\"\n",
    "r=session.get(url)\n",
    "keywords = ['销售经理']\n",
    "list_df=list()\n",
    "行业代号拆解={k:行业参数拆解(v)['industries']  for k,v in 行业字典.items()}\n",
    "行业代号拆解\n",
    "行业分类代号={k:行业参数拆解(v)['industryType']  for k,v in 行业字典.items()}\n",
    "行业分类代号\n",
    "for industryType in 行业分类代号.values():\n",
    "    for industries in 行业代号拆解.values():\n",
    "            for key in keywords:\n",
    "                翻页_参数={i:翻页url(行业url,industryType=[industryType],industries=[industries],key=[key],curPage_int = [i]  )\n",
    "               for i in  range(0,长度)\n",
    "      }\n",
    "                print (key,industryType,industries,长度)\n",
    "                for k,v in  翻页_参数.items():\n",
    "                    payload = v\n",
    "                    df = requests_liepin( url, params = payload)\n",
    "                    time.sleep(1+4*random())  #放慢脚步 3-7秒, 平均约5秒\n",
    "                    ## 备份\n",
    "                    #         df.to_csv(\"20春_Web数据挖掘_week04_liepin_{key}_{k}.tsv\"\\\n",
    "                    #                   .format(key=key, k=k), sep=\"\\t\", encoding=\"utf8\")\n",
    "\n",
    "                    df = df.assign (keyword = key)  # 区分  keyword    \n",
    "                    df = df.assign (curPage = k)  # 区分  curPage  \n",
    "#                     df = df.assign(行业 = industryType)\n",
    "#                     df = df.assign(行业细分 = industries)\n",
    "                    list_df.append(df)\n",
    "        \n",
    "df_行业 = pd.concat(list_df).reset_index()\n",
    "df_行业.index.name = '序'\n",
    "df_行业.to_excel(\"多个公司多个关键词\",encoding=\"utf-8\")"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 171,
   "metadata": {},
   "outputs": [],
   "source": [
    "# pd.Excelwriter(\"data_mining_week07\")\n",
    "with pd.ExcelWriter(\"C:/Users/ASUS/data_mining/week07/data_mining_week07.xlsx\") as writer:\n",
    "    df_多个关键词爬取.to_excel(writer,sheet_name=\"腾讯公司UX,产品经理,PRD,用户体验四个关键词的职位信息\")\n",
    "    df_all.to_excel(writer,sheet_name=\"多个公司多个关键词\")"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "# 城市爬取"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 5,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "['/zhaopin/?isAnalysis=&dqs=&pubTime=&salary=&compIds=&subIndustry=&industryType=&compscale=&key=%E6%95%B0%E6%8D%AE%E5%88%86%E6%9E%90%E5%B8%88&init=-1&searchType=1&headckid=aa4a3ef545437f22&flushckid=1&compkind=&fromSearchBtn=2&sortFlag=15&ckid=8f1da4637dfea0b5&jobKind=&industries=&clean_condition=&siTag=bFGQTbwE_AAQSb-u11jrBw%7EF5FSJAXvyHmQyODXqGxdVw&d_sfrom=search_prime&d_ckId=09cbba8b3315b002c02b731c3dd90b1d&d_curPage=0&d_pageSize=40&d_headId=591ebc1760fee953b72353bace17e6cc',\n",
       " '/zhaopin/?isAnalysis=&dqs=010&pubTime=&salary=&compIds=&subIndustry=&industryType=&compscale=&key=%E6%95%B0%E6%8D%AE%E5%88%86%E6%9E%90%E5%B8%88&init=-1&searchType=1&headckid=aa4a3ef545437f22&flushckid=1&compkind=&fromSearchBtn=2&sortFlag=15&ckid=8f1da4637dfea0b5&jobKind=&industries=&clean_condition=&siTag=bFGQTbwE_AAQSb-u11jrBw%7EF5FSJAXvyHmQyODXqGxdVw&d_sfrom=search_prime&d_ckId=09cbba8b3315b002c02b731c3dd90b1d&d_curPage=0&d_pageSize=40&d_headId=591ebc1760fee953b72353bace17e6cc',\n",
       " '/zhaopin/?isAnalysis=&dqs=020&pubTime=&salary=&compIds=&subIndustry=&industryType=&compscale=&key=%E6%95%B0%E6%8D%AE%E5%88%86%E6%9E%90%E5%B8%88&init=-1&searchType=1&headckid=aa4a3ef545437f22&flushckid=1&compkind=&fromSearchBtn=2&sortFlag=15&ckid=8f1da4637dfea0b5&jobKind=&industries=&clean_condition=&siTag=bFGQTbwE_AAQSb-u11jrBw%7EF5FSJAXvyHmQyODXqGxdVw&d_sfrom=search_prime&d_ckId=09cbba8b3315b002c02b731c3dd90b1d&d_curPage=0&d_pageSize=40&d_headId=591ebc1760fee953b72353bace17e6cc',\n",
       " '/zhaopin/?isAnalysis=&dqs=050020&pubTime=&salary=&compIds=&subIndustry=&industryType=&compscale=&key=%E6%95%B0%E6%8D%AE%E5%88%86%E6%9E%90%E5%B8%88&init=-1&searchType=1&headckid=aa4a3ef545437f22&flushckid=1&compkind=&fromSearchBtn=2&sortFlag=15&ckid=8f1da4637dfea0b5&jobKind=&industries=&clean_condition=&siTag=bFGQTbwE_AAQSb-u11jrBw%7EF5FSJAXvyHmQyODXqGxdVw&d_sfrom=search_prime&d_ckId=09cbba8b3315b002c02b731c3dd90b1d&d_curPage=0&d_pageSize=40&d_headId=591ebc1760fee953b72353bace17e6cc',\n",
       " '/zhaopin/?isAnalysis=&dqs=050090&pubTime=&salary=&compIds=&subIndustry=&industryType=&compscale=&key=%E6%95%B0%E6%8D%AE%E5%88%86%E6%9E%90%E5%B8%88&init=-1&searchType=1&headckid=aa4a3ef545437f22&flushckid=1&compkind=&fromSearchBtn=2&sortFlag=15&ckid=8f1da4637dfea0b5&jobKind=&industries=&clean_condition=&siTag=bFGQTbwE_AAQSb-u11jrBw%7EF5FSJAXvyHmQyODXqGxdVw&d_sfrom=search_prime&d_ckId=09cbba8b3315b002c02b731c3dd90b1d&d_curPage=0&d_pageSize=40&d_headId=591ebc1760fee953b72353bace17e6cc',\n",
       " '/zhaopin/?isAnalysis=&dqs=030&pubTime=&salary=&compIds=&subIndustry=&industryType=&compscale=&key=%E6%95%B0%E6%8D%AE%E5%88%86%E6%9E%90%E5%B8%88&init=-1&searchType=1&headckid=aa4a3ef545437f22&flushckid=1&compkind=&fromSearchBtn=2&sortFlag=15&ckid=8f1da4637dfea0b5&jobKind=&industries=&clean_condition=&siTag=bFGQTbwE_AAQSb-u11jrBw%7EF5FSJAXvyHmQyODXqGxdVw&d_sfrom=search_prime&d_ckId=09cbba8b3315b002c02b731c3dd90b1d&d_curPage=0&d_pageSize=40&d_headId=591ebc1760fee953b72353bace17e6cc',\n",
       " '/zhaopin/?isAnalysis=&dqs=060080&pubTime=&salary=&compIds=&subIndustry=&industryType=&compscale=&key=%E6%95%B0%E6%8D%AE%E5%88%86%E6%9E%90%E5%B8%88&init=-1&searchType=1&headckid=aa4a3ef545437f22&flushckid=1&compkind=&fromSearchBtn=2&sortFlag=15&ckid=8f1da4637dfea0b5&jobKind=&industries=&clean_condition=&siTag=bFGQTbwE_AAQSb-u11jrBw%7EF5FSJAXvyHmQyODXqGxdVw&d_sfrom=search_prime&d_ckId=09cbba8b3315b002c02b731c3dd90b1d&d_curPage=0&d_pageSize=40&d_headId=591ebc1760fee953b72353bace17e6cc',\n",
       " '/zhaopin/?isAnalysis=&dqs=040&pubTime=&salary=&compIds=&subIndustry=&industryType=&compscale=&key=%E6%95%B0%E6%8D%AE%E5%88%86%E6%9E%90%E5%B8%88&init=-1&searchType=1&headckid=aa4a3ef545437f22&flushckid=1&compkind=&fromSearchBtn=2&sortFlag=15&ckid=8f1da4637dfea0b5&jobKind=&industries=&clean_condition=&siTag=bFGQTbwE_AAQSb-u11jrBw%7EF5FSJAXvyHmQyODXqGxdVw&d_sfrom=search_prime&d_ckId=09cbba8b3315b002c02b731c3dd90b1d&d_curPage=0&d_pageSize=40&d_headId=591ebc1760fee953b72353bace17e6cc',\n",
       " '/zhaopin/?isAnalysis=&dqs=060020&pubTime=&salary=&compIds=&subIndustry=&industryType=&compscale=&key=%E6%95%B0%E6%8D%AE%E5%88%86%E6%9E%90%E5%B8%88&init=-1&searchType=1&headckid=aa4a3ef545437f22&flushckid=1&compkind=&fromSearchBtn=2&sortFlag=15&ckid=8f1da4637dfea0b5&jobKind=&industries=&clean_condition=&siTag=bFGQTbwE_AAQSb-u11jrBw%7EF5FSJAXvyHmQyODXqGxdVw&d_sfrom=search_prime&d_ckId=09cbba8b3315b002c02b731c3dd90b1d&d_curPage=0&d_pageSize=40&d_headId=591ebc1760fee953b72353bace17e6cc',\n",
       " '/zhaopin/?isAnalysis=&dqs=070020&pubTime=&salary=&compIds=&subIndustry=&industryType=&compscale=&key=%E6%95%B0%E6%8D%AE%E5%88%86%E6%9E%90%E5%B8%88&init=-1&searchType=1&headckid=aa4a3ef545437f22&flushckid=1&compkind=&fromSearchBtn=2&sortFlag=15&ckid=8f1da4637dfea0b5&jobKind=&industries=&clean_condition=&siTag=bFGQTbwE_AAQSb-u11jrBw%7EF5FSJAXvyHmQyODXqGxdVw&d_sfrom=search_prime&d_ckId=09cbba8b3315b002c02b731c3dd90b1d&d_curPage=0&d_pageSize=40&d_headId=591ebc1760fee953b72353bace17e6cc',\n",
       " '/zhaopin/?isAnalysis=&dqs=210040&pubTime=&salary=&compIds=&subIndustry=&industryType=&compscale=&key=%E6%95%B0%E6%8D%AE%E5%88%86%E6%9E%90%E5%B8%88&init=-1&searchType=1&headckid=aa4a3ef545437f22&flushckid=1&compkind=&fromSearchBtn=2&sortFlag=15&ckid=8f1da4637dfea0b5&jobKind=&industries=&clean_condition=&siTag=bFGQTbwE_AAQSb-u11jrBw%7EF5FSJAXvyHmQyODXqGxdVw&d_sfrom=search_prime&d_ckId=09cbba8b3315b002c02b731c3dd90b1d&d_curPage=0&d_pageSize=40&d_headId=591ebc1760fee953b72353bace17e6cc',\n",
       " '/zhaopin/?isAnalysis=&dqs=280020&pubTime=&salary=&compIds=&subIndustry=&industryType=&compscale=&key=%E6%95%B0%E6%8D%AE%E5%88%86%E6%9E%90%E5%B8%88&init=-1&searchType=1&headckid=aa4a3ef545437f22&flushckid=1&compkind=&fromSearchBtn=2&sortFlag=15&ckid=8f1da4637dfea0b5&jobKind=&industries=&clean_condition=&siTag=bFGQTbwE_AAQSb-u11jrBw%7EF5FSJAXvyHmQyODXqGxdVw&d_sfrom=search_prime&d_ckId=09cbba8b3315b002c02b731c3dd90b1d&d_curPage=0&d_pageSize=40&d_headId=591ebc1760fee953b72353bace17e6cc',\n",
       " '/zhaopin/?isAnalysis=&dqs=170020&pubTime=&salary=&compIds=&subIndustry=&industryType=&compscale=&key=%E6%95%B0%E6%8D%AE%E5%88%86%E6%9E%90%E5%B8%88&init=-1&searchType=1&headckid=aa4a3ef545437f22&flushckid=1&compkind=&fromSearchBtn=2&sortFlag=15&ckid=8f1da4637dfea0b5&jobKind=&industries=&clean_condition=&siTag=bFGQTbwE_AAQSb-u11jrBw%7EF5FSJAXvyHmQyODXqGxdVw&d_sfrom=search_prime&d_ckId=09cbba8b3315b002c02b731c3dd90b1d&d_curPage=0&d_pageSize=40&d_headId=591ebc1760fee953b72353bace17e6cc']"
      ]
     },
     "execution_count": 5,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "url=\"https://www.liepin.com/zhaopin/?isAnalysis=&dqs=010&pubTime=&salary=&compIds=&subIndustry=&industryType=&compscale=&key=%E6%95%B0%E6%8D%AE%E5%88%86%E6%9E%90%E5%B8%88&init=-1&searchType=1&headckid=aa4a3ef545437f22&flushckid=1&compkind=&fromSearchBtn=2&sortFlag=15&ckid=59a567b5b2b0ca8a&jobKind=&industries=&clean_condition=&siTag=bFGQTbwE_AAQSb-u11jrBw%7EfA9rXquZc5IkJpXC-Ycixw&d_sfrom=search_prime&d_ckId=1e731848b693d088091eaf7a0df76162&d_curPage=0&d_pageSize=40&d_headId=591ebc1760fee953b72353bace17e6cc\"\n",
    "r=session.get(url)\n",
    "xpath_城市=r.html.xpath(\"//div[@class='search-conditions']/dl[3]/dd/a[starts-with(@href,'/zhaopin')]\")\n",
    "xpath_城市\n",
    "城市字典={x.xpath(\"a/text()\")[0]:x.xpath(\"a/@href\")[0]  for x in xpath_城市}\n",
    "城市字典\n",
    "城市列表=[x.xpath(\"a/@href\")[0] for x in xpath_城市]\n",
    "城市列表"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 6,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>key</th>\n",
       "      <th>init</th>\n",
       "      <th>searchType</th>\n",
       "      <th>headckid</th>\n",
       "      <th>flushckid</th>\n",
       "      <th>fromSearchBtn</th>\n",
       "      <th>sortFlag</th>\n",
       "      <th>ckid</th>\n",
       "      <th>siTag</th>\n",
       "      <th>d_sfrom</th>\n",
       "      <th>d_ckId</th>\n",
       "      <th>d_curPage</th>\n",
       "      <th>d_pageSize</th>\n",
       "      <th>d_headId</th>\n",
       "      <th>dqs</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>aa4a3ef545437f22</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>8f1da4637dfea0b5</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~F5FSJAXvyHmQyODXqGxdVw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>09cbba8b3315b002c02b731c3dd90b1d</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "      <td>NaN</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>aa4a3ef545437f22</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>8f1da4637dfea0b5</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~F5FSJAXvyHmQyODXqGxdVw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>09cbba8b3315b002c02b731c3dd90b1d</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "      <td>010</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>aa4a3ef545437f22</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>8f1da4637dfea0b5</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~F5FSJAXvyHmQyODXqGxdVw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>09cbba8b3315b002c02b731c3dd90b1d</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "      <td>020</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>3</th>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>aa4a3ef545437f22</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>8f1da4637dfea0b5</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~F5FSJAXvyHmQyODXqGxdVw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>09cbba8b3315b002c02b731c3dd90b1d</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "      <td>050020</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>4</th>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>aa4a3ef545437f22</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>8f1da4637dfea0b5</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~F5FSJAXvyHmQyODXqGxdVw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>09cbba8b3315b002c02b731c3dd90b1d</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "      <td>050090</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>5</th>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>aa4a3ef545437f22</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>8f1da4637dfea0b5</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~F5FSJAXvyHmQyODXqGxdVw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>09cbba8b3315b002c02b731c3dd90b1d</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "      <td>030</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>6</th>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>aa4a3ef545437f22</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>8f1da4637dfea0b5</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~F5FSJAXvyHmQyODXqGxdVw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>09cbba8b3315b002c02b731c3dd90b1d</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "      <td>060080</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>7</th>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>aa4a3ef545437f22</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>8f1da4637dfea0b5</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~F5FSJAXvyHmQyODXqGxdVw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>09cbba8b3315b002c02b731c3dd90b1d</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "      <td>040</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>8</th>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>aa4a3ef545437f22</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>8f1da4637dfea0b5</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~F5FSJAXvyHmQyODXqGxdVw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>09cbba8b3315b002c02b731c3dd90b1d</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "      <td>060020</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>9</th>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>aa4a3ef545437f22</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>8f1da4637dfea0b5</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~F5FSJAXvyHmQyODXqGxdVw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>09cbba8b3315b002c02b731c3dd90b1d</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "      <td>070020</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>10</th>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>aa4a3ef545437f22</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>8f1da4637dfea0b5</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~F5FSJAXvyHmQyODXqGxdVw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>09cbba8b3315b002c02b731c3dd90b1d</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "      <td>210040</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>11</th>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>aa4a3ef545437f22</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>8f1da4637dfea0b5</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~F5FSJAXvyHmQyODXqGxdVw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>09cbba8b3315b002c02b731c3dd90b1d</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "      <td>280020</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>12</th>\n",
       "      <td>数据分析师</td>\n",
       "      <td>-1</td>\n",
       "      <td>1</td>\n",
       "      <td>aa4a3ef545437f22</td>\n",
       "      <td>1</td>\n",
       "      <td>2</td>\n",
       "      <td>15</td>\n",
       "      <td>8f1da4637dfea0b5</td>\n",
       "      <td>bFGQTbwE_AAQSb-u11jrBw~F5FSJAXvyHmQyODXqGxdVw</td>\n",
       "      <td>search_prime</td>\n",
       "      <td>09cbba8b3315b002c02b731c3dd90b1d</td>\n",
       "      <td>0</td>\n",
       "      <td>40</td>\n",
       "      <td>591ebc1760fee953b72353bace17e6cc</td>\n",
       "      <td>170020</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "      key init searchType          headckid flushckid fromSearchBtn sortFlag  \\\n",
       "0   数据分析师   -1          1  aa4a3ef545437f22         1             2       15   \n",
       "1   数据分析师   -1          1  aa4a3ef545437f22         1             2       15   \n",
       "2   数据分析师   -1          1  aa4a3ef545437f22         1             2       15   \n",
       "3   数据分析师   -1          1  aa4a3ef545437f22         1             2       15   \n",
       "4   数据分析师   -1          1  aa4a3ef545437f22         1             2       15   \n",
       "5   数据分析师   -1          1  aa4a3ef545437f22         1             2       15   \n",
       "6   数据分析师   -1          1  aa4a3ef545437f22         1             2       15   \n",
       "7   数据分析师   -1          1  aa4a3ef545437f22         1             2       15   \n",
       "8   数据分析师   -1          1  aa4a3ef545437f22         1             2       15   \n",
       "9   数据分析师   -1          1  aa4a3ef545437f22         1             2       15   \n",
       "10  数据分析师   -1          1  aa4a3ef545437f22         1             2       15   \n",
       "11  数据分析师   -1          1  aa4a3ef545437f22         1             2       15   \n",
       "12  数据分析师   -1          1  aa4a3ef545437f22         1             2       15   \n",
       "\n",
       "                ckid                                          siTag  \\\n",
       "0   8f1da4637dfea0b5  bFGQTbwE_AAQSb-u11jrBw~F5FSJAXvyHmQyODXqGxdVw   \n",
       "1   8f1da4637dfea0b5  bFGQTbwE_AAQSb-u11jrBw~F5FSJAXvyHmQyODXqGxdVw   \n",
       "2   8f1da4637dfea0b5  bFGQTbwE_AAQSb-u11jrBw~F5FSJAXvyHmQyODXqGxdVw   \n",
       "3   8f1da4637dfea0b5  bFGQTbwE_AAQSb-u11jrBw~F5FSJAXvyHmQyODXqGxdVw   \n",
       "4   8f1da4637dfea0b5  bFGQTbwE_AAQSb-u11jrBw~F5FSJAXvyHmQyODXqGxdVw   \n",
       "5   8f1da4637dfea0b5  bFGQTbwE_AAQSb-u11jrBw~F5FSJAXvyHmQyODXqGxdVw   \n",
       "6   8f1da4637dfea0b5  bFGQTbwE_AAQSb-u11jrBw~F5FSJAXvyHmQyODXqGxdVw   \n",
       "7   8f1da4637dfea0b5  bFGQTbwE_AAQSb-u11jrBw~F5FSJAXvyHmQyODXqGxdVw   \n",
       "8   8f1da4637dfea0b5  bFGQTbwE_AAQSb-u11jrBw~F5FSJAXvyHmQyODXqGxdVw   \n",
       "9   8f1da4637dfea0b5  bFGQTbwE_AAQSb-u11jrBw~F5FSJAXvyHmQyODXqGxdVw   \n",
       "10  8f1da4637dfea0b5  bFGQTbwE_AAQSb-u11jrBw~F5FSJAXvyHmQyODXqGxdVw   \n",
       "11  8f1da4637dfea0b5  bFGQTbwE_AAQSb-u11jrBw~F5FSJAXvyHmQyODXqGxdVw   \n",
       "12  8f1da4637dfea0b5  bFGQTbwE_AAQSb-u11jrBw~F5FSJAXvyHmQyODXqGxdVw   \n",
       "\n",
       "         d_sfrom                            d_ckId d_curPage d_pageSize  \\\n",
       "0   search_prime  09cbba8b3315b002c02b731c3dd90b1d         0         40   \n",
       "1   search_prime  09cbba8b3315b002c02b731c3dd90b1d         0         40   \n",
       "2   search_prime  09cbba8b3315b002c02b731c3dd90b1d         0         40   \n",
       "3   search_prime  09cbba8b3315b002c02b731c3dd90b1d         0         40   \n",
       "4   search_prime  09cbba8b3315b002c02b731c3dd90b1d         0         40   \n",
       "5   search_prime  09cbba8b3315b002c02b731c3dd90b1d         0         40   \n",
       "6   search_prime  09cbba8b3315b002c02b731c3dd90b1d         0         40   \n",
       "7   search_prime  09cbba8b3315b002c02b731c3dd90b1d         0         40   \n",
       "8   search_prime  09cbba8b3315b002c02b731c3dd90b1d         0         40   \n",
       "9   search_prime  09cbba8b3315b002c02b731c3dd90b1d         0         40   \n",
       "10  search_prime  09cbba8b3315b002c02b731c3dd90b1d         0         40   \n",
       "11  search_prime  09cbba8b3315b002c02b731c3dd90b1d         0         40   \n",
       "12  search_prime  09cbba8b3315b002c02b731c3dd90b1d         0         40   \n",
       "\n",
       "                            d_headId     dqs  \n",
       "0   591ebc1760fee953b72353bace17e6cc     NaN  \n",
       "1   591ebc1760fee953b72353bace17e6cc     010  \n",
       "2   591ebc1760fee953b72353bace17e6cc     020  \n",
       "3   591ebc1760fee953b72353bace17e6cc  050020  \n",
       "4   591ebc1760fee953b72353bace17e6cc  050090  \n",
       "5   591ebc1760fee953b72353bace17e6cc     030  \n",
       "6   591ebc1760fee953b72353bace17e6cc  060080  \n",
       "7   591ebc1760fee953b72353bace17e6cc     040  \n",
       "8   591ebc1760fee953b72353bace17e6cc  060020  \n",
       "9   591ebc1760fee953b72353bace17e6cc  070020  \n",
       "10  591ebc1760fee953b72353bace17e6cc  210040  \n",
       "11  591ebc1760fee953b72353bace17e6cc  280020  \n",
       "12  591ebc1760fee953b72353bace17e6cc  170020  "
      ]
     },
     "execution_count": 6,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "def 城市参数拆解(url):\n",
    "    sixpart=urlparse(url)\n",
    "    out=parse_qs(sixpart.query)\n",
    "    return out\n",
    "城市参数=城市参数拆解( 城市列表[0])\n",
    "df_城市=pd.DataFrame([urlparse(x) for x in 城市列表 ])\n",
    "\n",
    "df_城市_qs=pd.DataFrame([{k:v[0]   \n",
    "                         if len(v[0])>=1  else 0 \\\n",
    "                        for k,v in parse_qs(x).items() }for x in df_城市['query']])\n",
    "# df_城市_qs.loc[0,[\"dqs\"]].fillna(0)\n",
    "df_城市_qs\n",
    "#df_城市_qs.nunique()\n",
    "#唯一值是dqs"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 17,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "{'key': ['数据分析师'],\n",
       " 'init': ['-1'],\n",
       " 'searchType': ['1'],\n",
       " 'headckid': ['aa4a3ef545437f22'],\n",
       " 'flushckid': ['1'],\n",
       " 'fromSearchBtn': ['2'],\n",
       " 'sortFlag': ['15'],\n",
       " 'ckid': ['8f1da4637dfea0b5'],\n",
       " 'siTag': ['bFGQTbwE_AAQSb-u11jrBw~F5FSJAXvyHmQyODXqGxdVw'],\n",
       " 'd_sfrom': ['search_prime'],\n",
       " 'd_ckId': ['09cbba8b3315b002c02b731c3dd90b1d'],\n",
       " 'd_curPage': ['0'],\n",
       " 'd_pageSize': ['40'],\n",
       " 'd_headId': ['591ebc1760fee953b72353bace17e6cc'],\n",
       " 'dqs': ['']}"
      ]
     },
     "execution_count": 17,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "def 城市参数拆解(url):\n",
    "    sixpart=urlparse(url)\n",
    "    out=parse_qs(sixpart.query)\n",
    "    return out\n",
    "城市参数=城市参数拆解( 城市列表[0])\n",
    "城市参数['dqs']=['']\n",
    "城市参数\n",
    "def 城市参数调整(dqs,key):\n",
    "    参数=城市参数.copy()\n",
    "    参数['dqs']=dqs\n",
    "    参数['key']=key\n",
    "    return 参数\n",
    "# 城市参数代号={k:城市参数调整(v) for k,v in 城市字典.items()}\n",
    "# 城市参数代号\n",
    "城市参数"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 37,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>城市</th>\n",
       "      <th>城市代号</th>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>索引</th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>全国</td>\n",
       "      <td>NaN</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td>北京</td>\n",
       "      <td>010</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>上海</td>\n",
       "      <td>020</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>3</th>\n",
       "      <td>广州</td>\n",
       "      <td>050020</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>4</th>\n",
       "      <td>深圳</td>\n",
       "      <td>050090</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>5</th>\n",
       "      <td>天津</td>\n",
       "      <td>030</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>6</th>\n",
       "      <td>苏州</td>\n",
       "      <td>060080</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>7</th>\n",
       "      <td>重庆</td>\n",
       "      <td>040</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>8</th>\n",
       "      <td>南京</td>\n",
       "      <td>060020</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>9</th>\n",
       "      <td>杭州</td>\n",
       "      <td>070020</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>10</th>\n",
       "      <td>大连</td>\n",
       "      <td>210040</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>11</th>\n",
       "      <td>成都</td>\n",
       "      <td>280020</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>12</th>\n",
       "      <td>武汉</td>\n",
       "      <td>170020</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "    城市    城市代号\n",
       "索引            \n",
       "0   全国     NaN\n",
       "1   北京     010\n",
       "2   上海     020\n",
       "3   广州  050020\n",
       "4   深圳  050090\n",
       "5   天津     030\n",
       "6   苏州  060080\n",
       "7   重庆     040\n",
       "8   南京  060020\n",
       "9   杭州  070020\n",
       "10  大连  210040\n",
       "11  成都  280020\n",
       "12  武汉  170020"
      ]
     },
     "execution_count": 37,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "城市代号=pd.DataFrame(df_城市_qs['dqs'])\n",
    "\n",
    "城市代号.index.name='索引'\n",
    "城市名称=pd.DataFrame(城市字典.keys())\n",
    "城市名称.index.name='索引'\n",
    "城市编号=pd.merge(城市名称,城市代号,on='索引').rename(columns={0:\"城市\",\"dqs\":\"城市代号\"})\n",
    "城市编号"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## 翻页"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 116,
   "metadata": {
    "code_folding": []
   },
   "outputs": [
    {
     "data": {
      "text/plain": [
       "{0: {'key': ['数据挖掘'],\n",
       "  'init': ['-1'],\n",
       "  'searchType': ['1'],\n",
       "  'headckid': ['aa4a3ef545437f22'],\n",
       "  'flushckid': ['1'],\n",
       "  'fromSearchBtn': ['2'],\n",
       "  'sortFlag': ['15'],\n",
       "  'ckid': ['8f1da4637dfea0b5'],\n",
       "  'siTag': ['bFGQTbwE_AAQSb-u11jrBw~F5FSJAXvyHmQyODXqGxdVw'],\n",
       "  'd_sfrom': ['search_prime'],\n",
       "  'd_ckId': ['09cbba8b3315b002c02b731c3dd90b1d'],\n",
       "  'd_curPage': ['0'],\n",
       "  'd_pageSize': ['40'],\n",
       "  'd_headId': ['591ebc1760fee953b72353bace17e6cc'],\n",
       "  'dqs': [''],\n",
       "  'curPage_int': [0]},\n",
       " 1: {'key': ['数据挖掘'],\n",
       "  'init': ['-1'],\n",
       "  'searchType': ['1'],\n",
       "  'headckid': ['aa4a3ef545437f22'],\n",
       "  'flushckid': ['1'],\n",
       "  'fromSearchBtn': ['2'],\n",
       "  'sortFlag': ['15'],\n",
       "  'ckid': ['8f1da4637dfea0b5'],\n",
       "  'siTag': ['bFGQTbwE_AAQSb-u11jrBw~F5FSJAXvyHmQyODXqGxdVw'],\n",
       "  'd_sfrom': ['search_prime'],\n",
       "  'd_ckId': ['09cbba8b3315b002c02b731c3dd90b1d'],\n",
       "  'd_curPage': ['0'],\n",
       "  'd_pageSize': ['40'],\n",
       "  'd_headId': ['591ebc1760fee953b72353bace17e6cc'],\n",
       "  'dqs': [''],\n",
       "  'curPage_int': [1]},\n",
       " 2: {'key': ['数据挖掘'],\n",
       "  'init': ['-1'],\n",
       "  'searchType': ['1'],\n",
       "  'headckid': ['aa4a3ef545437f22'],\n",
       "  'flushckid': ['1'],\n",
       "  'fromSearchBtn': ['2'],\n",
       "  'sortFlag': ['15'],\n",
       "  'ckid': ['8f1da4637dfea0b5'],\n",
       "  'siTag': ['bFGQTbwE_AAQSb-u11jrBw~F5FSJAXvyHmQyODXqGxdVw'],\n",
       "  'd_sfrom': ['search_prime'],\n",
       "  'd_ckId': ['09cbba8b3315b002c02b731c3dd90b1d'],\n",
       "  'd_curPage': ['0'],\n",
       "  'd_pageSize': ['40'],\n",
       "  'd_headId': ['591ebc1760fee953b72353bace17e6cc'],\n",
       "  'dqs': [''],\n",
       "  'curPage_int': [2]},\n",
       " 3: {'key': ['数据挖掘'],\n",
       "  'init': ['-1'],\n",
       "  'searchType': ['1'],\n",
       "  'headckid': ['aa4a3ef545437f22'],\n",
       "  'flushckid': ['1'],\n",
       "  'fromSearchBtn': ['2'],\n",
       "  'sortFlag': ['15'],\n",
       "  'ckid': ['8f1da4637dfea0b5'],\n",
       "  'siTag': ['bFGQTbwE_AAQSb-u11jrBw~F5FSJAXvyHmQyODXqGxdVw'],\n",
       "  'd_sfrom': ['search_prime'],\n",
       "  'd_ckId': ['09cbba8b3315b002c02b731c3dd90b1d'],\n",
       "  'd_curPage': ['0'],\n",
       "  'd_pageSize': ['40'],\n",
       "  'd_headId': ['591ebc1760fee953b72353bace17e6cc'],\n",
       "  'dqs': [''],\n",
       "  'curPage_int': [3]},\n",
       " 4: {'key': ['数据挖掘'],\n",
       "  'init': ['-1'],\n",
       "  'searchType': ['1'],\n",
       "  'headckid': ['aa4a3ef545437f22'],\n",
       "  'flushckid': ['1'],\n",
       "  'fromSearchBtn': ['2'],\n",
       "  'sortFlag': ['15'],\n",
       "  'ckid': ['8f1da4637dfea0b5'],\n",
       "  'siTag': ['bFGQTbwE_AAQSb-u11jrBw~F5FSJAXvyHmQyODXqGxdVw'],\n",
       "  'd_sfrom': ['search_prime'],\n",
       "  'd_ckId': ['09cbba8b3315b002c02b731c3dd90b1d'],\n",
       "  'd_curPage': ['0'],\n",
       "  'd_pageSize': ['40'],\n",
       "  'd_headId': ['591ebc1760fee953b72353bace17e6cc'],\n",
       "  'dqs': [''],\n",
       "  'curPage_int': [4]},\n",
       " 5: {'key': ['数据挖掘'],\n",
       "  'init': ['-1'],\n",
       "  'searchType': ['1'],\n",
       "  'headckid': ['aa4a3ef545437f22'],\n",
       "  'flushckid': ['1'],\n",
       "  'fromSearchBtn': ['2'],\n",
       "  'sortFlag': ['15'],\n",
       "  'ckid': ['8f1da4637dfea0b5'],\n",
       "  'siTag': ['bFGQTbwE_AAQSb-u11jrBw~F5FSJAXvyHmQyODXqGxdVw'],\n",
       "  'd_sfrom': ['search_prime'],\n",
       "  'd_ckId': ['09cbba8b3315b002c02b731c3dd90b1d'],\n",
       "  'd_curPage': ['0'],\n",
       "  'd_pageSize': ['40'],\n",
       "  'd_headId': ['591ebc1760fee953b72353bace17e6cc'],\n",
       "  'dqs': [''],\n",
       "  'curPage_int': [5]},\n",
       " 6: {'key': ['数据挖掘'],\n",
       "  'init': ['-1'],\n",
       "  'searchType': ['1'],\n",
       "  'headckid': ['aa4a3ef545437f22'],\n",
       "  'flushckid': ['1'],\n",
       "  'fromSearchBtn': ['2'],\n",
       "  'sortFlag': ['15'],\n",
       "  'ckid': ['8f1da4637dfea0b5'],\n",
       "  'siTag': ['bFGQTbwE_AAQSb-u11jrBw~F5FSJAXvyHmQyODXqGxdVw'],\n",
       "  'd_sfrom': ['search_prime'],\n",
       "  'd_ckId': ['09cbba8b3315b002c02b731c3dd90b1d'],\n",
       "  'd_curPage': ['0'],\n",
       "  'd_pageSize': ['40'],\n",
       "  'd_headId': ['591ebc1760fee953b72353bace17e6cc'],\n",
       "  'dqs': [''],\n",
       "  'curPage_int': [6]},\n",
       " 7: {'key': ['数据挖掘'],\n",
       "  'init': ['-1'],\n",
       "  'searchType': ['1'],\n",
       "  'headckid': ['aa4a3ef545437f22'],\n",
       "  'flushckid': ['1'],\n",
       "  'fromSearchBtn': ['2'],\n",
       "  'sortFlag': ['15'],\n",
       "  'ckid': ['8f1da4637dfea0b5'],\n",
       "  'siTag': ['bFGQTbwE_AAQSb-u11jrBw~F5FSJAXvyHmQyODXqGxdVw'],\n",
       "  'd_sfrom': ['search_prime'],\n",
       "  'd_ckId': ['09cbba8b3315b002c02b731c3dd90b1d'],\n",
       "  'd_curPage': ['0'],\n",
       "  'd_pageSize': ['40'],\n",
       "  'd_headId': ['591ebc1760fee953b72353bace17e6cc'],\n",
       "  'dqs': [''],\n",
       "  'curPage_int': [7]},\n",
       " 8: {'key': ['数据挖掘'],\n",
       "  'init': ['-1'],\n",
       "  'searchType': ['1'],\n",
       "  'headckid': ['aa4a3ef545437f22'],\n",
       "  'flushckid': ['1'],\n",
       "  'fromSearchBtn': ['2'],\n",
       "  'sortFlag': ['15'],\n",
       "  'ckid': ['8f1da4637dfea0b5'],\n",
       "  'siTag': ['bFGQTbwE_AAQSb-u11jrBw~F5FSJAXvyHmQyODXqGxdVw'],\n",
       "  'd_sfrom': ['search_prime'],\n",
       "  'd_ckId': ['09cbba8b3315b002c02b731c3dd90b1d'],\n",
       "  'd_curPage': ['0'],\n",
       "  'd_pageSize': ['40'],\n",
       "  'd_headId': ['591ebc1760fee953b72353bace17e6cc'],\n",
       "  'dqs': [''],\n",
       "  'curPage_int': [8]},\n",
       " 9: {'key': ['数据挖掘'],\n",
       "  'init': ['-1'],\n",
       "  'searchType': ['1'],\n",
       "  'headckid': ['aa4a3ef545437f22'],\n",
       "  'flushckid': ['1'],\n",
       "  'fromSearchBtn': ['2'],\n",
       "  'sortFlag': ['15'],\n",
       "  'ckid': ['8f1da4637dfea0b5'],\n",
       "  'siTag': ['bFGQTbwE_AAQSb-u11jrBw~F5FSJAXvyHmQyODXqGxdVw'],\n",
       "  'd_sfrom': ['search_prime'],\n",
       "  'd_ckId': ['09cbba8b3315b002c02b731c3dd90b1d'],\n",
       "  'd_curPage': ['0'],\n",
       "  'd_pageSize': ['40'],\n",
       "  'd_headId': ['591ebc1760fee953b72353bace17e6cc'],\n",
       "  'dqs': [''],\n",
       "  'curPage_int': [9]}}"
      ]
     },
     "execution_count": 116,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "url=\"https://www.liepin.com/zhaopin/?isAnalysis=&dqs=010&pubTime=&salary=&compIds=&subIndustry=&industryType=&compscale=&key=%E6%95%B0%E6%8D%AE%E5%88%86%E6%9E%90%E5%B8%88&init=-1&searchType=1&headckid=aa4a3ef545437f22&flushckid=1&compkind=&fromSearchBtn=2&sortFlag=15&ckid=59a567b5b2b0ca8a&jobKind=&industries=&clean_condition=&siTag=bFGQTbwE_AAQSb-u11jrBw%7EfA9rXquZc5IkJpXC-Ycixw&d_sfrom=search_prime&d_ckId=1e731848b693d088091eaf7a0df76162&d_curPage=0&d_pageSize=40&d_headId=591ebc1760fee953b72353bace17e6cc\"\n",
    "r=session.get(url)\n",
    "xpath_翻页a = '//div[@class=\"pagerbar\"]/a[starts-with(@href,\"/zhaopin\")]'\n",
    "城市列表=[x.xpath('//@href')[0] for x in r.html.xpath(xpath_翻页a)]\n",
    "df=pd.DataFrame([urlparse(x) for x in 城市列表 ])\n",
    "df_qs =pd.DataFrame([{ k:v[0] for k,v in parse_qs(x).items()}for x in df['query']])\n",
    "df_qs = df_qs.assign (curPage_int=df_qs.curPage.astype(int)) \n",
    "df_qs\n",
    "长度=int(df_qs.curPage_int.max()+1)\n",
    "def 翻页_参数拆解(url):\n",
    "    sixpart=urlparse(url)\n",
    "    out=parse_qs(sixpart.query)\n",
    "    return out\n",
    "\n",
    "翻页_参数模板=翻页_参数拆解(城市列表[0])\n",
    "翻页_参数模板\n",
    "def 翻页_参数调整(key,dqs,curPage_int):\n",
    "    参数=城市参数.copy()\n",
    "    参数['dqs']=dqs\n",
    "    参数['key']=key\n",
    "    参数['curPage_int']=curPage_int\n",
    "    return 参数\n",
    "#翻页_城市\n",
    "翻页_城市_参数={i:翻页_参数调整(key=['数据挖掘'],dqs=[''],curPage_int=[i]  )for i in  range(0,长度)  }\n",
    "翻页_城市_参数"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## 指定城市多个关键词进行爬取"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 118,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "法语翻译 10\n",
      "金融分析师 10\n",
      "大数据 10\n",
      "用户体验 10\n"
     ]
    },
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>index</th>\n",
       "      <th>edu</th>\n",
       "      <th>经验</th>\n",
       "      <th>薪水</th>\n",
       "      <th>时间</th>\n",
       "      <th>职称</th>\n",
       "      <th>公司地点</th>\n",
       "      <th>公司名称</th>\n",
       "      <th>链结</th>\n",
       "      <th>公司URL</th>\n",
       "      <th>keyword</th>\n",
       "      <th>curPage</th>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>索引</th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>0</td>\n",
       "      <td>统招本科</td>\n",
       "      <td>经验不限</td>\n",
       "      <td>面议</td>\n",
       "      <td>2020年04月16日</td>\n",
       "      <td>法语翻译</td>\n",
       "      <td>上海-徐汇区</td>\n",
       "      <td>汉唐文化</td>\n",
       "      <td>https://www.liepin.com/job/1916434197.shtml</td>\n",
       "      <td>https://www.liepin.com/company/8858794/</td>\n",
       "      <td>法语翻译</td>\n",
       "      <td>0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td>1</td>\n",
       "      <td>大专及以上</td>\n",
       "      <td>经验不限</td>\n",
       "      <td>3-8k·12薪</td>\n",
       "      <td>2020年04月08日</td>\n",
       "      <td>德语翻译/法语翻译（长期有效）</td>\n",
       "      <td>上海-江湾</td>\n",
       "      <td>上海创凌翻译服务有限公司</td>\n",
       "      <td>https://www.liepin.com/job/1920987859.shtml</td>\n",
       "      <td>https://www.liepin.com/company/8074861/</td>\n",
       "      <td>法语翻译</td>\n",
       "      <td>0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>2</td>\n",
       "      <td>大专及以上</td>\n",
       "      <td>经验不限</td>\n",
       "      <td>6-11k·12薪</td>\n",
       "      <td>2020年04月07日</td>\n",
       "      <td>法语翻译</td>\n",
       "      <td>上海-浦东新区</td>\n",
       "      <td>上海华依科技发展股份有限公司</td>\n",
       "      <td>https://www.liepin.com/job/1924507893.shtml</td>\n",
       "      <td>https://www.liepin.com/company/7884428/</td>\n",
       "      <td>法语翻译</td>\n",
       "      <td>0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>3</th>\n",
       "      <td>3</td>\n",
       "      <td>本科及以上</td>\n",
       "      <td>1-3年</td>\n",
       "      <td>10-11k·12薪</td>\n",
       "      <td>2020年03月15日</td>\n",
       "      <td>法语翻译</td>\n",
       "      <td>上海</td>\n",
       "      <td>上海正译科技发展有限公司</td>\n",
       "      <td>https://www.liepin.com/job/1920016997.shtml</td>\n",
       "      <td>https://www.liepin.com/company/10039511/</td>\n",
       "      <td>法语翻译</td>\n",
       "      <td>0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>4</th>\n",
       "      <td>4</td>\n",
       "      <td>统招本科</td>\n",
       "      <td>1-3年</td>\n",
       "      <td>20-30k·12薪</td>\n",
       "      <td>2020年03月12日</td>\n",
       "      <td>法语翻译专员</td>\n",
       "      <td>上海</td>\n",
       "      <td>宁波商诚科技服务有限公司</td>\n",
       "      <td>https://www.liepin.com/job/1918954935.shtml</td>\n",
       "      <td>https://www.liepin.com/company/9758975/</td>\n",
       "      <td>法语翻译</td>\n",
       "      <td>0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>...</th>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1385</th>\n",
       "      <td>35</td>\n",
       "      <td>学历不限</td>\n",
       "      <td>3-5年</td>\n",
       "      <td>20-25k·13薪</td>\n",
       "      <td>2020年04月23日</td>\n",
       "      <td>UX leader</td>\n",
       "      <td>上海</td>\n",
       "      <td>某外资运动零售</td>\n",
       "      <td>https://www.liepin.com/a/19541743.shtml</td>\n",
       "      <td></td>\n",
       "      <td>用户体验</td>\n",
       "      <td>9</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1386</th>\n",
       "      <td>36</td>\n",
       "      <td>统招本科</td>\n",
       "      <td>5-10年</td>\n",
       "      <td>67-83k·12薪</td>\n",
       "      <td>2020年04月23日</td>\n",
       "      <td>ued总监</td>\n",
       "      <td>上海</td>\n",
       "      <td>国际著名运动品牌</td>\n",
       "      <td>https://www.liepin.com/a/19112579.shtml</td>\n",
       "      <td></td>\n",
       "      <td>用户体验</td>\n",
       "      <td>9</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1387</th>\n",
       "      <td>37</td>\n",
       "      <td>本科及以上</td>\n",
       "      <td>1-3年</td>\n",
       "      <td>10-25k·12薪</td>\n",
       "      <td>2020年04月23日</td>\n",
       "      <td>交互设计</td>\n",
       "      <td>上海</td>\n",
       "      <td>上海奈格教育培训有限公司</td>\n",
       "      <td>https://www.liepin.com/job/1915987819.shtml</td>\n",
       "      <td>https://www.liepin.com/company/9629249/</td>\n",
       "      <td>用户体验</td>\n",
       "      <td>9</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1388</th>\n",
       "      <td>38</td>\n",
       "      <td>统招本科</td>\n",
       "      <td>3-5年</td>\n",
       "      <td>20-30k·14薪</td>\n",
       "      <td>2020年04月23日</td>\n",
       "      <td>高级UE交互设计师</td>\n",
       "      <td>上海-新桥</td>\n",
       "      <td>巨人网络</td>\n",
       "      <td>https://www.liepin.com/job/196267669.shtml</td>\n",
       "      <td>https://www.liepin.com/company/7871067/</td>\n",
       "      <td>用户体验</td>\n",
       "      <td>9</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1389</th>\n",
       "      <td>39</td>\n",
       "      <td>统招本科</td>\n",
       "      <td>3-5年</td>\n",
       "      <td>20-30k·14薪</td>\n",
       "      <td>2020年04月23日</td>\n",
       "      <td>高级UX交互设计师</td>\n",
       "      <td>上海-普陀区</td>\n",
       "      <td>某知名互联网医疗健康企业</td>\n",
       "      <td>https://www.liepin.com/a/16175721.shtml</td>\n",
       "      <td></td>\n",
       "      <td>用户体验</td>\n",
       "      <td>9</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "<p>1390 rows × 12 columns</p>\n",
       "</div>"
      ],
      "text/plain": [
       "      index    edu     经验          薪水           时间               职称     公司地点  \\\n",
       "索引                                                                             \n",
       "0         0   统招本科   经验不限          面议  2020年04月16日             法语翻译   上海-徐汇区   \n",
       "1         1  大专及以上   经验不限    3-8k·12薪  2020年04月08日  德语翻译/法语翻译（长期有效）    上海-江湾   \n",
       "2         2  大专及以上   经验不限   6-11k·12薪  2020年04月07日             法语翻译  上海-浦东新区   \n",
       "3         3  本科及以上   1-3年  10-11k·12薪  2020年03月15日             法语翻译       上海   \n",
       "4         4   统招本科   1-3年  20-30k·12薪  2020年03月12日           法语翻译专员       上海   \n",
       "...     ...    ...    ...         ...          ...              ...      ...   \n",
       "1385     35   学历不限   3-5年  20-25k·13薪  2020年04月23日        UX leader       上海   \n",
       "1386     36   统招本科  5-10年  67-83k·12薪  2020年04月23日            ued总监       上海   \n",
       "1387     37  本科及以上   1-3年  10-25k·12薪  2020年04月23日             交互设计       上海   \n",
       "1388     38   统招本科   3-5年  20-30k·14薪  2020年04月23日        高级UE交互设计师    上海-新桥   \n",
       "1389     39   统招本科   3-5年  20-30k·14薪  2020年04月23日        高级UX交互设计师   上海-普陀区   \n",
       "\n",
       "                公司名称                                           链结  \\\n",
       "索引                                                                  \n",
       "0               汉唐文化  https://www.liepin.com/job/1916434197.shtml   \n",
       "1       上海创凌翻译服务有限公司  https://www.liepin.com/job/1920987859.shtml   \n",
       "2     上海华依科技发展股份有限公司  https://www.liepin.com/job/1924507893.shtml   \n",
       "3       上海正译科技发展有限公司  https://www.liepin.com/job/1920016997.shtml   \n",
       "4       宁波商诚科技服务有限公司  https://www.liepin.com/job/1918954935.shtml   \n",
       "...              ...                                          ...   \n",
       "1385         某外资运动零售      https://www.liepin.com/a/19541743.shtml   \n",
       "1386        国际著名运动品牌      https://www.liepin.com/a/19112579.shtml   \n",
       "1387    上海奈格教育培训有限公司  https://www.liepin.com/job/1915987819.shtml   \n",
       "1388            巨人网络   https://www.liepin.com/job/196267669.shtml   \n",
       "1389    某知名互联网医疗健康企业      https://www.liepin.com/a/16175721.shtml   \n",
       "\n",
       "                                         公司URL keyword  curPage  \n",
       "索引                                                               \n",
       "0      https://www.liepin.com/company/8858794/    法语翻译        0  \n",
       "1      https://www.liepin.com/company/8074861/    法语翻译        0  \n",
       "2      https://www.liepin.com/company/7884428/    法语翻译        0  \n",
       "3     https://www.liepin.com/company/10039511/    法语翻译        0  \n",
       "4      https://www.liepin.com/company/9758975/    法语翻译        0  \n",
       "...                                        ...     ...      ...  \n",
       "1385                                              用户体验        9  \n",
       "1386                                              用户体验        9  \n",
       "1387   https://www.liepin.com/company/9629249/    用户体验        9  \n",
       "1388   https://www.liepin.com/company/7871067/    用户体验        9  \n",
       "1389                                              用户体验        9  \n",
       "\n",
       "[1390 rows x 12 columns]"
      ]
     },
     "execution_count": 118,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "import time\n",
    "from random import random\n",
    "from requests_html import HTMLSession\n",
    "session =HTMLSession()\n",
    "url=\"https://www.liepin.com/zhaopin/\"\n",
    "r=session.get(url)\n",
    "keywords = ['法语翻译','金融分析师','大数据','用户体验']\n",
    "list_df=list()\n",
    "for key in keywords:\n",
    "    翻页_城市_参数={i:翻页_参数调整(key=[key],dqs=['020'],curPage_int=[i]  )for i in  range(0,长度)  }\n",
    "    print (key,长度)\n",
    "    for k,v in  翻页_城市_参数.items():\n",
    "        payload = v\n",
    "        df = requests_liepin( url, params = payload)\n",
    "        time.sleep(1+4*random())  #放慢脚步 3-7秒, 平均约5秒\n",
    "#         ## 备份\n",
    "#         df.to_csv(\"20春_Web数据挖掘_week04_liepin_{key}_{k}.tsv\"\\\n",
    "#                   .format(key=key, k=k), sep=\"\\t\", encoding=\"utf8\")\n",
    "\n",
    "        df = df.assign (keyword = key)  # 区分  keyword    \n",
    "        df = df.assign (curPage = k)  # 区分  curPage   \n",
    "        \n",
    "        list_df.append(df)\n",
    "        \n",
    "df_指定城市= pd.concat(list_df).reset_index()\n",
    "df_指定城市.index.name = '索引'\n",
    "df_指定城市"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## 指定全国范围"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 121,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "法语翻译 10\n",
      "算法工程师 10\n",
      "大数据 10\n",
      "婚礼策划师 10\n"
     ]
    },
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>index</th>\n",
       "      <th>edu</th>\n",
       "      <th>经验</th>\n",
       "      <th>薪水</th>\n",
       "      <th>时间</th>\n",
       "      <th>职称</th>\n",
       "      <th>公司地点</th>\n",
       "      <th>公司名称</th>\n",
       "      <th>链结</th>\n",
       "      <th>公司URL</th>\n",
       "      <th>keyword</th>\n",
       "      <th>curPage</th>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>索引</th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>0</td>\n",
       "      <td>本科及以上</td>\n",
       "      <td>经验不限</td>\n",
       "      <td>4-9k·13薪</td>\n",
       "      <td>2020年04月23日</td>\n",
       "      <td>法语翻译</td>\n",
       "      <td>郑州</td>\n",
       "      <td>郑州云之竹电子科技有限公司</td>\n",
       "      <td>https://www.liepin.com/job/1927694165.shtml</td>\n",
       "      <td>https://www.liepin.com/company/12218649/</td>\n",
       "      <td>法语翻译</td>\n",
       "      <td>0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td>1</td>\n",
       "      <td>本科及以上</td>\n",
       "      <td>1-3年</td>\n",
       "      <td>15-20k·12薪</td>\n",
       "      <td>2020年04月23日</td>\n",
       "      <td>刚果金法语翻译</td>\n",
       "      <td></td>\n",
       "      <td>北京盛伦国际物流有限公司</td>\n",
       "      <td>https://www.liepin.com/job/1925671671.shtml</td>\n",
       "      <td>https://www.liepin.com/company/2038317/</td>\n",
       "      <td>法语翻译</td>\n",
       "      <td>0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>2</td>\n",
       "      <td>大专及以上</td>\n",
       "      <td>经验不限</td>\n",
       "      <td>9-18k·12薪</td>\n",
       "      <td>2020年04月23日</td>\n",
       "      <td>法语翻译（审校标注）</td>\n",
       "      <td>成都-高新区</td>\n",
       "      <td>文思海辉</td>\n",
       "      <td>https://www.liepin.com/job/1925619201.shtml</td>\n",
       "      <td>https://www.liepin.com/company/2038105/</td>\n",
       "      <td>法语翻译</td>\n",
       "      <td>0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>3</th>\n",
       "      <td>3</td>\n",
       "      <td>统招本科</td>\n",
       "      <td>经验不限</td>\n",
       "      <td>11-20k·12薪</td>\n",
       "      <td>2020年04月23日</td>\n",
       "      <td>法语翻译（审校标注）</td>\n",
       "      <td></td>\n",
       "      <td>文思海辉</td>\n",
       "      <td>https://www.liepin.com/job/1925619101.shtml</td>\n",
       "      <td>https://www.liepin.com/company/2038105/</td>\n",
       "      <td>法语翻译</td>\n",
       "      <td>0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>4</th>\n",
       "      <td>4</td>\n",
       "      <td>本科及以上</td>\n",
       "      <td>1-3年</td>\n",
       "      <td>面议</td>\n",
       "      <td>2020年04月23日</td>\n",
       "      <td>法语翻译</td>\n",
       "      <td></td>\n",
       "      <td>中建材信息技术股份有限公司</td>\n",
       "      <td>https://www.liepin.com/job/1924744695.shtml</td>\n",
       "      <td>https://www.liepin.com/company/8657187/</td>\n",
       "      <td>法语翻译</td>\n",
       "      <td>0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>...</th>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1595</th>\n",
       "      <td>35</td>\n",
       "      <td>本科及以上</td>\n",
       "      <td>经验不限</td>\n",
       "      <td>4-8k·12薪</td>\n",
       "      <td>2019年10月07日</td>\n",
       "      <td>婚礼策划师招聘可学习</td>\n",
       "      <td>成都</td>\n",
       "      <td>四川新美麦田文化传播有限责任公司</td>\n",
       "      <td>https://www.liepin.com/job/1922703895.shtml</td>\n",
       "      <td>https://www.liepin.com/company/10151065/</td>\n",
       "      <td>婚礼策划师</td>\n",
       "      <td>9</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1596</th>\n",
       "      <td>36</td>\n",
       "      <td>学历不限</td>\n",
       "      <td>经验不限</td>\n",
       "      <td>2-6k·12薪</td>\n",
       "      <td>2019年09月29日</td>\n",
       "      <td>婚礼策划师</td>\n",
       "      <td>南昌</td>\n",
       "      <td>南昌魔都文化传媒有限公司</td>\n",
       "      <td>https://www.liepin.com/job/1923848031.shtml</td>\n",
       "      <td>https://www.liepin.com/company/10212901/</td>\n",
       "      <td>婚礼策划师</td>\n",
       "      <td>9</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1597</th>\n",
       "      <td>37</td>\n",
       "      <td>学历不限</td>\n",
       "      <td>3-5年</td>\n",
       "      <td>9-15k·12薪</td>\n",
       "      <td>2019年09月19日</td>\n",
       "      <td>婚礼策划师</td>\n",
       "      <td></td>\n",
       "      <td>北京鼎雄科技有限公司</td>\n",
       "      <td>https://www.liepin.com/job/1919443713.shtml</td>\n",
       "      <td>https://www.liepin.com/company/9679896/</td>\n",
       "      <td>婚礼策划师</td>\n",
       "      <td>9</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1598</th>\n",
       "      <td>38</td>\n",
       "      <td>大专及以上</td>\n",
       "      <td>经验不限</td>\n",
       "      <td>4-9k·12薪</td>\n",
       "      <td>2019年09月16日</td>\n",
       "      <td>婚礼策划师</td>\n",
       "      <td>衢州</td>\n",
       "      <td>衢州喜铺文化传媒有限公司</td>\n",
       "      <td>https://www.liepin.com/job/1923430303.shtml</td>\n",
       "      <td>https://www.liepin.com/company/10195903/</td>\n",
       "      <td>婚礼策划师</td>\n",
       "      <td>9</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1599</th>\n",
       "      <td>39</td>\n",
       "      <td>中专/中技及以上</td>\n",
       "      <td>1-3年</td>\n",
       "      <td>8-10k·12薪</td>\n",
       "      <td>2019年09月13日</td>\n",
       "      <td>婚礼策划师</td>\n",
       "      <td>上海-浦东新区</td>\n",
       "      <td>上海伊铭萱婚庆服务股份有限公司</td>\n",
       "      <td>https://www.liepin.com/job/1923399083.shtml</td>\n",
       "      <td>https://www.liepin.com/company/9332681/</td>\n",
       "      <td>婚礼策划师</td>\n",
       "      <td>9</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "<p>1600 rows × 12 columns</p>\n",
       "</div>"
      ],
      "text/plain": [
       "      index       edu    经验          薪水           时间          职称     公司地点  \\\n",
       "索引                                                                          \n",
       "0         0     本科及以上  经验不限    4-9k·13薪  2020年04月23日        法语翻译       郑州   \n",
       "1         1     本科及以上  1-3年  15-20k·12薪  2020年04月23日     刚果金法语翻译            \n",
       "2         2     大专及以上  经验不限   9-18k·12薪  2020年04月23日  法语翻译（审校标注）   成都-高新区   \n",
       "3         3      统招本科  经验不限  11-20k·12薪  2020年04月23日  法语翻译（审校标注）            \n",
       "4         4     本科及以上  1-3年          面议  2020年04月23日        法语翻译            \n",
       "...     ...       ...   ...         ...          ...         ...      ...   \n",
       "1595     35     本科及以上  经验不限    4-8k·12薪  2019年10月07日  婚礼策划师招聘可学习       成都   \n",
       "1596     36      学历不限  经验不限    2-6k·12薪  2019年09月29日       婚礼策划师       南昌   \n",
       "1597     37      学历不限  3-5年   9-15k·12薪  2019年09月19日       婚礼策划师            \n",
       "1598     38     大专及以上  经验不限    4-9k·12薪  2019年09月16日       婚礼策划师       衢州   \n",
       "1599     39  中专/中技及以上  1-3年   8-10k·12薪  2019年09月13日       婚礼策划师  上海-浦东新区   \n",
       "\n",
       "                  公司名称                                           链结  \\\n",
       "索引                                                                    \n",
       "0        郑州云之竹电子科技有限公司  https://www.liepin.com/job/1927694165.shtml   \n",
       "1         北京盛伦国际物流有限公司  https://www.liepin.com/job/1925671671.shtml   \n",
       "2                 文思海辉  https://www.liepin.com/job/1925619201.shtml   \n",
       "3                 文思海辉  https://www.liepin.com/job/1925619101.shtml   \n",
       "4        中建材信息技术股份有限公司  https://www.liepin.com/job/1924744695.shtml   \n",
       "...                ...                                          ...   \n",
       "1595  四川新美麦田文化传播有限责任公司  https://www.liepin.com/job/1922703895.shtml   \n",
       "1596      南昌魔都文化传媒有限公司  https://www.liepin.com/job/1923848031.shtml   \n",
       "1597        北京鼎雄科技有限公司  https://www.liepin.com/job/1919443713.shtml   \n",
       "1598      衢州喜铺文化传媒有限公司  https://www.liepin.com/job/1923430303.shtml   \n",
       "1599   上海伊铭萱婚庆服务股份有限公司  https://www.liepin.com/job/1923399083.shtml   \n",
       "\n",
       "                                         公司URL keyword  curPage  \n",
       "索引                                                               \n",
       "0     https://www.liepin.com/company/12218649/    法语翻译        0  \n",
       "1      https://www.liepin.com/company/2038317/    法语翻译        0  \n",
       "2      https://www.liepin.com/company/2038105/    法语翻译        0  \n",
       "3      https://www.liepin.com/company/2038105/    法语翻译        0  \n",
       "4      https://www.liepin.com/company/8657187/    法语翻译        0  \n",
       "...                                        ...     ...      ...  \n",
       "1595  https://www.liepin.com/company/10151065/   婚礼策划师        9  \n",
       "1596  https://www.liepin.com/company/10212901/   婚礼策划师        9  \n",
       "1597   https://www.liepin.com/company/9679896/   婚礼策划师        9  \n",
       "1598  https://www.liepin.com/company/10195903/   婚礼策划师        9  \n",
       "1599   https://www.liepin.com/company/9332681/   婚礼策划师        9  \n",
       "\n",
       "[1600 rows x 12 columns]"
      ]
     },
     "execution_count": 121,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "import time\n",
    "from random import random\n",
    "from requests_html import HTMLSession\n",
    "session =HTMLSession()\n",
    "url=\"https://www.liepin.com/zhaopin/\"\n",
    "r=session.get(url)\n",
    "keywords = ['法语翻译','算法工程师','大数据','婚礼策划师']\n",
    "list_df=list()\n",
    "for key in keywords:\n",
    "    翻页_城市_参数={i:翻页_参数调整(key=[key],dqs=[''],curPage_int=[i]  )for i in  range(0,长度)  }\n",
    "    print (key,长度)\n",
    "    for k,v in  翻页_城市_参数.items():\n",
    "        payload = v\n",
    "        df = requests_liepin( url, params = payload)\n",
    "        time.sleep(1+4*random())  #放慢脚步 3-7秒, 平均约5秒\n",
    "#         ## 备份\n",
    "#         df.to_csv(\"20春_Web数据挖掘_week04_liepin_{key}_{k}.tsv\"\\\n",
    "#                   .format(key=key, k=k), sep=\"\\t\", encoding=\"utf8\")\n",
    "\n",
    "        df = df.assign (keyword = key)  # 区分  keyword    \n",
    "        df = df.assign (curPage = k)  # 区分  curPage    \n",
    "        list_df.append(df)\n",
    "        \n",
    "df_全国= pd.concat(list_df).reset_index()\n",
    "df_全国.index.name = '索引'\n",
    "df_全国"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## 多个城市搜索多个职位"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 122,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "Python工程师 020 10\n",
      "java 020 10\n",
      "Python工程师 040 10\n",
      "java 040 10\n",
      "Python工程师 170020 10\n",
      "java 170020 10\n"
     ]
    },
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>index</th>\n",
       "      <th>edu</th>\n",
       "      <th>经验</th>\n",
       "      <th>薪水</th>\n",
       "      <th>时间</th>\n",
       "      <th>职称</th>\n",
       "      <th>公司地点</th>\n",
       "      <th>公司名称</th>\n",
       "      <th>链结</th>\n",
       "      <th>公司URL</th>\n",
       "      <th>keyword</th>\n",
       "      <th>curPage</th>\n",
       "      <th>citynumber</th>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>索引</th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>0</td>\n",
       "      <td>本科及以上</td>\n",
       "      <td>3-5年</td>\n",
       "      <td>15-30k·12薪</td>\n",
       "      <td>2020年04月23日</td>\n",
       "      <td>高级Python开发工程师</td>\n",
       "      <td>上海-延吉</td>\n",
       "      <td>上海骞云信息科技有限公司</td>\n",
       "      <td>https://www.liepin.com/job/1927511605.shtml</td>\n",
       "      <td>https://www.liepin.com/company/8859024/</td>\n",
       "      <td>Python工程师</td>\n",
       "      <td>0</td>\n",
       "      <td>020</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td>1</td>\n",
       "      <td>大专及以上</td>\n",
       "      <td>3-5年</td>\n",
       "      <td>11-20k·12薪</td>\n",
       "      <td>2020年04月23日</td>\n",
       "      <td>Python全栈工程师</td>\n",
       "      <td>上海</td>\n",
       "      <td>百联</td>\n",
       "      <td>https://www.liepin.com/job/1927355201.shtml</td>\n",
       "      <td>https://www.liepin.com/company/8504136/</td>\n",
       "      <td>Python工程师</td>\n",
       "      <td>0</td>\n",
       "      <td>020</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>2</td>\n",
       "      <td>本科及以上</td>\n",
       "      <td>3-5年</td>\n",
       "      <td>20-35k·12薪</td>\n",
       "      <td>2020年04月23日</td>\n",
       "      <td>全栈工程师-python</td>\n",
       "      <td>上海-张江</td>\n",
       "      <td>Kyligence</td>\n",
       "      <td>https://www.liepin.com/job/1927297685.shtml</td>\n",
       "      <td>https://www.liepin.com/company/9183362/</td>\n",
       "      <td>Python工程师</td>\n",
       "      <td>0</td>\n",
       "      <td>020</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>3</th>\n",
       "      <td>3</td>\n",
       "      <td>本科及以上</td>\n",
       "      <td>经验不限</td>\n",
       "      <td>10-20k·13薪</td>\n",
       "      <td>2020年04月23日</td>\n",
       "      <td>python软件开发工程师</td>\n",
       "      <td>上海-浦东新区</td>\n",
       "      <td>上海思勰投资管理有限公司</td>\n",
       "      <td>https://www.liepin.com/job/1927261279.shtml</td>\n",
       "      <td>https://www.liepin.com/company/9268080/</td>\n",
       "      <td>Python工程师</td>\n",
       "      <td>0</td>\n",
       "      <td>020</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>4</th>\n",
       "      <td>4</td>\n",
       "      <td>统招本科</td>\n",
       "      <td>3-5年</td>\n",
       "      <td>15-25k·12薪</td>\n",
       "      <td>2020年04月23日</td>\n",
       "      <td>Python全栈工程师</td>\n",
       "      <td>上海-田林</td>\n",
       "      <td>上海柯林布瑞</td>\n",
       "      <td>https://www.liepin.com/job/1927062427.shtml</td>\n",
       "      <td>https://www.liepin.com/company/8541615/</td>\n",
       "      <td>Python工程师</td>\n",
       "      <td>0</td>\n",
       "      <td>020</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>...</th>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2135</th>\n",
       "      <td>35</td>\n",
       "      <td>统招本科</td>\n",
       "      <td>1-3年</td>\n",
       "      <td>3-6k·12薪</td>\n",
       "      <td>2020年04月23日</td>\n",
       "      <td>Java后端开发实习生</td>\n",
       "      <td>武汉-洪山区</td>\n",
       "      <td>武汉宙源科技有限公司</td>\n",
       "      <td>https://www.liepin.com/job/1925206757.shtml</td>\n",
       "      <td>https://www.liepin.com/company/9901831/</td>\n",
       "      <td>java</td>\n",
       "      <td>9</td>\n",
       "      <td>170020</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2136</th>\n",
       "      <td>36</td>\n",
       "      <td>统招本科</td>\n",
       "      <td>3-5年</td>\n",
       "      <td>8-13k·13薪</td>\n",
       "      <td>2020年04月23日</td>\n",
       "      <td>java工程师</td>\n",
       "      <td>武汉</td>\n",
       "      <td>华工赛百</td>\n",
       "      <td>https://www.liepin.com/job/1924543637.shtml</td>\n",
       "      <td>https://www.liepin.com/company/8061550/</td>\n",
       "      <td>java</td>\n",
       "      <td>9</td>\n",
       "      <td>170020</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2137</th>\n",
       "      <td>37</td>\n",
       "      <td>本科及以上</td>\n",
       "      <td>5-10年</td>\n",
       "      <td>8-15k·17薪</td>\n",
       "      <td>2020年04月23日</td>\n",
       "      <td>大数据开发工程师（Java方向）</td>\n",
       "      <td>武汉-关山</td>\n",
       "      <td>武汉中海庭数据技术有限公司</td>\n",
       "      <td>https://www.liepin.com/job/1924368911.shtml</td>\n",
       "      <td>https://www.liepin.com/company/9644059/</td>\n",
       "      <td>java</td>\n",
       "      <td>9</td>\n",
       "      <td>170020</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2138</th>\n",
       "      <td>38</td>\n",
       "      <td>本科及以上</td>\n",
       "      <td>1-3年</td>\n",
       "      <td>6-12k·13薪</td>\n",
       "      <td>2020年04月23日</td>\n",
       "      <td>java开发工程师-武汉</td>\n",
       "      <td>武汉-武昌区</td>\n",
       "      <td>福州半云科技有限公司</td>\n",
       "      <td>https://www.liepin.com/job/1924191491.shtml</td>\n",
       "      <td>https://www.liepin.com/company/9341925/</td>\n",
       "      <td>java</td>\n",
       "      <td>9</td>\n",
       "      <td>170020</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2139</th>\n",
       "      <td>39</td>\n",
       "      <td>统招本科</td>\n",
       "      <td>3-5年</td>\n",
       "      <td>8-15k·12薪</td>\n",
       "      <td>2020年04月23日</td>\n",
       "      <td>WCS开发工程师（Java）</td>\n",
       "      <td>武汉-汉阳区</td>\n",
       "      <td>浙江凯乐士科技有限公司</td>\n",
       "      <td>https://www.liepin.com/job/1922486697.shtml</td>\n",
       "      <td>https://www.liepin.com/company/9303632/</td>\n",
       "      <td>java</td>\n",
       "      <td>9</td>\n",
       "      <td>170020</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "<p>2140 rows × 13 columns</p>\n",
       "</div>"
      ],
      "text/plain": [
       "      index    edu     经验          薪水           时间                职称     公司地点  \\\n",
       "索引                                                                              \n",
       "0         0  本科及以上   3-5年  15-30k·12薪  2020年04月23日     高级Python开发工程师    上海-延吉   \n",
       "1         1  大专及以上   3-5年  11-20k·12薪  2020年04月23日       Python全栈工程师       上海   \n",
       "2         2  本科及以上   3-5年  20-35k·12薪  2020年04月23日      全栈工程师-python    上海-张江   \n",
       "3         3  本科及以上   经验不限  10-20k·13薪  2020年04月23日     python软件开发工程师  上海-浦东新区   \n",
       "4         4   统招本科   3-5年  15-25k·12薪  2020年04月23日       Python全栈工程师    上海-田林   \n",
       "...     ...    ...    ...         ...          ...               ...      ...   \n",
       "2135     35   统招本科   1-3年    3-6k·12薪  2020年04月23日       Java后端开发实习生   武汉-洪山区   \n",
       "2136     36   统招本科   3-5年   8-13k·13薪  2020年04月23日           java工程师       武汉   \n",
       "2137     37  本科及以上  5-10年   8-15k·17薪  2020年04月23日  大数据开发工程师（Java方向）    武汉-关山   \n",
       "2138     38  本科及以上   1-3年   6-12k·13薪  2020年04月23日      java开发工程师-武汉   武汉-武昌区   \n",
       "2139     39   统招本科   3-5年   8-15k·12薪  2020年04月23日    WCS开发工程师（Java）   武汉-汉阳区   \n",
       "\n",
       "               公司名称                                           链结  \\\n",
       "索引                                                                 \n",
       "0      上海骞云信息科技有限公司  https://www.liepin.com/job/1927511605.shtml   \n",
       "1                百联  https://www.liepin.com/job/1927355201.shtml   \n",
       "2         Kyligence  https://www.liepin.com/job/1927297685.shtml   \n",
       "3      上海思勰投资管理有限公司  https://www.liepin.com/job/1927261279.shtml   \n",
       "4            上海柯林布瑞  https://www.liepin.com/job/1927062427.shtml   \n",
       "...             ...                                          ...   \n",
       "2135     武汉宙源科技有限公司  https://www.liepin.com/job/1925206757.shtml   \n",
       "2136           华工赛百  https://www.liepin.com/job/1924543637.shtml   \n",
       "2137  武汉中海庭数据技术有限公司  https://www.liepin.com/job/1924368911.shtml   \n",
       "2138     福州半云科技有限公司  https://www.liepin.com/job/1924191491.shtml   \n",
       "2139    浙江凯乐士科技有限公司  https://www.liepin.com/job/1922486697.shtml   \n",
       "\n",
       "                                        公司URL    keyword  curPage citynumber  \n",
       "索引                                                                            \n",
       "0     https://www.liepin.com/company/8859024/  Python工程师        0        020  \n",
       "1     https://www.liepin.com/company/8504136/  Python工程师        0        020  \n",
       "2     https://www.liepin.com/company/9183362/  Python工程师        0        020  \n",
       "3     https://www.liepin.com/company/9268080/  Python工程师        0        020  \n",
       "4     https://www.liepin.com/company/8541615/  Python工程师        0        020  \n",
       "...                                       ...        ...      ...        ...  \n",
       "2135  https://www.liepin.com/company/9901831/       java        9     170020  \n",
       "2136  https://www.liepin.com/company/8061550/       java        9     170020  \n",
       "2137  https://www.liepin.com/company/9644059/       java        9     170020  \n",
       "2138  https://www.liepin.com/company/9341925/       java        9     170020  \n",
       "2139  https://www.liepin.com/company/9303632/       java        9     170020  \n",
       "\n",
       "[2140 rows x 13 columns]"
      ]
     },
     "execution_count": 122,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "import time\n",
    "from random import random\n",
    "from requests_html import HTMLSession\n",
    "session =HTMLSession()\n",
    "url=\"https://www.liepin.com/zhaopin/\"\n",
    "r=session.get(url)\n",
    "keywords = ['Python工程师','java']\n",
    "list_df=list()\n",
    "#指定上海，重庆，武汉三个城市\n",
    "citygroup=['020','040','170020']\n",
    "for city in citygroup:\n",
    "        for key in keywords:\n",
    "            翻页_城市_参数={i:翻页_参数调整(key=[key],dqs=[city],curPage_int=[i]  )for i in  range(0,长度)  }\n",
    "            print (key,city,长度)\n",
    "            for k,v in  翻页_城市_参数.items():\n",
    "                payload = v\n",
    "                df = requests_liepin( url, params = payload)\n",
    "                time.sleep(1+4*random())  #放慢脚步 3-7秒, 平均约5秒\n",
    "        #         ## 备份\n",
    "        #         df.to_csv(\"20春_Web数据挖掘_week04_liepin_{key}_{k}.tsv\"\\\n",
    "        #                   .format(key=key, k=k), sep=\"\\t\", encoding=\"utf8\")\n",
    "\n",
    "                df = df.assign (keyword = key)  # 区分  keyword    \n",
    "                df = df.assign (curPage = k)  # 区分  curPage \n",
    "                df = df.assign (citynumber = city) \n",
    "                list_df.append(df)\n",
    "        \n",
    "df_多个城市= pd.concat(list_df).reset_index()\n",
    "df_多个城市.index.name = '索引'\n",
    "df_多个城市"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 157,
   "metadata": {},
   "outputs": [],
   "source": [
    "with pd.ExcelWriter(\"C:/Users/ASUS/data_mining/week07/data_mining_week07_不同城市.xlsx\") as writer:\n",
    "    df_指定城市.to_excel(writer,sheet_name=\"指定城市搜索多个职位\")\n",
    "    df_多个城市.to_excel(writer,sheet_name=\"多个城市搜索多个职位\")\n",
    "    df_全国.to_excel(writer,sheet_name=\"全国范围搜索多个职位\")"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {},
   "outputs": [],
   "source": []
  }
 ],
 "metadata": {
  "kernelspec": {
   "display_name": "Python 3",
   "language": "python",
   "name": "python3"
  },
  "language_info": {
   "codemirror_mode": {
    "name": "ipython",
    "version": 3
   },
   "file_extension": ".py",
   "mimetype": "text/x-python",
   "name": "python",
   "nbconvert_exporter": "python",
   "pygments_lexer": "ipython3",
   "version": "3.7.6"
  },
  "toc": {
   "base_numbering": 1,
   "nav_menu": {},
   "number_sections": true,
   "sideBar": true,
   "skip_h1_title": false,
   "title_cell": "Table of Contents",
   "title_sidebar": "Contents",
   "toc_cell": false,
   "toc_position": {
    "height": "calc(100% - 180px)",
    "left": "10px",
    "top": "150px",
    "width": "284.427px"
   },
   "toc_section_display": true,
   "toc_window_display": true
  }
 },
 "nbformat": 4,
 "nbformat_minor": 4
}
